<html xmlns:v>
<head>
<meta http-equiv='content-type' content='text/html;charset=gb2312'>
<meta name='gemeratpr' content='网络程序员伴侣(lshdic)2004'>
<meta name="download url" content="http://www.lshdic.com/downlshdic.asp">
<title>淘气鬼</title>
<style>
v\:*{behavior:url(#default#vml);} //声明变量v为vml对象
*{font-size:12px;color:;}
a{text-decoration:none;}
a:hover{color:red;}
</style>
</head>
<body topmargin='2' leftmargin='2' bgcolor=black style='border:1 solid green'>
<base target='_top'>
<table id='' bgcolor='' cellspacing='2' cellpadding='2' border='1' width='300' height='300' style='color:white'>
<tr>
<td>普通html内容</td>
<td>普通html内容</td>
</tr>
<tr>
<td>普通html内容</td>
<td>普通html内容</td>
</tr>
</table>
<v:oval fillcolor='green' id=oval1 style='position:absolute;width:100;height:100;z-index:6'> <!--制作一个渐变形状-->
<v:stroke color='white'/> <!--这是边框可以不要-->
<v:fill type='gradientradial' opacity='0' color2='yellow' id='fill1'/>
</v:oval>
<script>
//原作:风云舞,载自http://www.lshdic.com/bbs
//没什么无聊写着玩,叫它“淘气鬼”好了,放在网页中也很有意思呵呵
var wid,hei //定义全局存储变量,主要为提高速度
wid=document.body.offsetwidth-50;hei=document.body.offsetheight-50 //首次启动将宽与高放进变量
function document.onmousemove(){ //鼠标移动时
oval1.style.left=math.abs(wid-event.x-50);oval1.style.top=math.abs(hei-event.y-50); //物体位置
temp1=math.round(100/(wid/event.x));temp2=math.round(100/(hei/event.y)) //计算x与y的百分比
fill1.focusposition=temp1+"%,"+temp2+"%";fill1.focussize=temp1/9+"%,"+temp2/9+"%";oval1.style.width=100+math.abs(temp1-50);oval1.style.height=100+math.abs(temp2-50) //更新物体形状
}
function window.onresize(){
wid=document.body.offsetwidth-50;hei=document.body.offsetheight-50 //窗体改变大小时刷新变量
}
</script>
</body>
</html>