Welcome visitor
* Login
* Register
It is currently March 19th, 2019, 7:55 am
All times are UTC [ DST ]
* Search
View unanswered posts - View active topics

FORUMS » Client Side » JavaScript



Post new topic Reply to topic  [ 2 posts ] 
Author Message
  Close Window in 2 minutes with Javascript
PostPosted: March 3rd, 2009, 9:54 pm 
User avatar

Posts: 63
I know about all the inconveniencies about depending on JS, nevertheless i would like to give it a try.

What i have is a window that pops-up another one. Now, if you are an existing user you can keep the window open, but if you are not, then the window will close automatically on 2 min. I already know everything abut the registration and stuff, my only question is about the javascript i need to close the window. Thanks for any help, im just a newbie on this javascript things.


Top
 Profile  
 
  Re: Close Window in 2 minutes with Javascript
PostPosted: March 3rd, 2009, 10:11 pm 
User avatar

Posts: 81
for the closing window
<html>
<head>
<script type="text/javascript">
var min=0;
var time;
function closee(){
time=setTimeout("closee()",60000);
if (min==2){window.close();}
min=min+1;
}
</script>
</head>
<body onLoad="closee();">
</body>
</html>
and javascript only can close a window it opened


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

FORUMS » Client Side » JavaScript


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron