如何使IE震动?
将下面的代码,加入到<body>与</body>之间即可!(欣赏效果:
我要使IE震动 )
<SCRIPT LANGUAGE="JavaScript">
<!--
var MrBicklesworth = navigator.appName;
var dur = 4;
var count = 0;
var dir = 1;
var speed = [8,4,2,1];
var steps = 0;
var dirs = [-1,1];
var MiniMe;
function leo() {
parent.window.moveBy(speed[steps]*dirs[dir=1-dir],0);
count++;
if (count < dur) {
setTimeout("leo()",70/speed[steps]);
}
else if (steps<(speed.length-1)) {
steps++;
count=0;
leo();
}
if (steps >= 4) {}
}
-->
</SCRIPT>
<p><a href="javascript:leo()">我要使IE震动</a></p>
|