Try pasting the relevant bits into your page.
IE4+ and NN4+ allow to capture the mouse move event and then to
position an image as needed to let it follow the mouse cursor:
<HTML>
<HEAD>
<STYLE>
#imgLayer { position: absolute; visibility: hidden; }
</style>
<SCRIPT>
var imgURL =
'
var started = false;
function moveHandler (evt) {
if (document.layers) {
var l = document.imgLayer;
if (l) {
l.left = window.pageXOffset + evt.pageX + 1;
l.top = window.pageYOffset + evt.pageY + 1;
if (!started) {
started = true;
l.visibility = 'show';
}
}
}
else if (document.all) {
var l = document.all.imgLayer;
if (l) {
l.style.pixelLeft = document.body.scrollLeft + event.x + 1;
l.style.pixelTop = document.body.scrollTop + event.y + 1;
if (!started) {
started = true;
l.style.visibility = 'visible';
}
}
}
else if (document.getElementById) {
var l = document.getElementById('imgLayer');
if (l) {
l.style.left = window.pageXOffset + evt.clientX + 1 + 'px';
l.style.top = window.pageYOffset + evt.clientY + 1 + 'px';
if (!started) {
started = true;
l.style.visibility = 'visible';
}
}
}
}
function initEvents () {
if (document.layers)
document.captureEvents(Event.MOUSEMOVE);
document.onmousemove = moveHandler;
}
initEvents();
</script>
</head>
<BODY>
<SPAN ID="imgLayer">
<SCRIPT>
document.write('<IMG SRC="' + imgURL + '">');
</script>
</span>
</body>
</html>