"francisco lopez" <bu**********@gmx.net> wrote in message
news:b0************************@posting.google.com ...
hi,
well I think I will forget the earthquake-effect, because it doesn´t
run in a frame with IE,
so I need now another funny prank, but not the format C: fake, I was
thinking for example that a little windows will open and when you try
to close it, it allways jumps away from the cursor, this would be
funny, well any idea is wellcome, hope that this time someone can
help.
regards
francisco
This move's a small popup window around.
Not very good but this might get you thinking.
Enhancement #1: onMouseOver the window not just the words.
Enhancement #2: randomize the movement.
<html>
<head>
<title>mover.htm</title>
<script type="text/javascript">
var winx = 100;
var winy = 50;
var winz = ",width=" + winx + ",height=" + winy;
var html = "<html><head><title>mover</title>";
html += "<" + "script type='text/javascript'>";
html += "var winx = " + winx + ";";
html += "var winy = " + winy + ";";
html += "function mover() {";
html += " var x = window.event.screenX + 50;";
html += " var y = window.event.screenY + 50;";
html += " if (screen.width - winx - x < 0) {";
html += " x = window.event.screenX - 150;";
html += " }";
html += " if (screen.Height - winy - y < 0) {";
html += " y = window.event.screenY - 150;";
html += " }";
html += " moveTo(x,y);";
html += "}";
html += "<" + "/script></head><body>";
html += "<span onmouseover='mover()'>";
html += "<center><b>Alt+F4<br>to close.</b></center>";
html += "</span>";
html += "</body></html>";
function mover() {
var wind = window.open("","hmtl","statusbar=0" + winz);
wind.document.write(html);
}
</script>
</head>
<body>
<a href="javascript
:mover()">mover()</a>
</body>
</html>