JavaScript Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsProgrammingJavaScript Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
SlickEdit: Code in over 40 languages across 7 platforms. SlickEdit’s unmatched power, speed, and flexibility allows even the most accomplished developers to write better code faster. Download a free trial today!
  #1  
Old November 14th, 2005, 11:37 AM
skelterweb skelterweb is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Nov 2005
Posts: 13 skelterweb User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 6 h 50 m 45 sec
Reputation Power: 0
Prompt window

how can i made a prompt window appears after 1 minute of window no events?
it should appear everytime users take no action (key or mouse) during a certain time (eg 1 minute).
i found timeout() but i cant associate it with window events.

can anyone help me with this one?

thanks

Reply With Quote
  #2  
Old November 15th, 2005, 02:56 PM
ChiefWigs1982's Avatar
ChiefWigs1982 ChiefWigs1982 is offline
Contributing User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jan 2005
Location: I have emerged from the place of spells and fairies
Posts: 97 ChiefWigs1982 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 Days 17 h 35 m 12 sec
Reputation Power: 4
Here is a script I made that will redirect the browser if the user is
inactive for 5 seconds.

Should be easy enough for you to adapt it to suite your needs...
Code:
<script type="text/JavaScript">
var timer;
if (document.all)
{
	document.onmousemove=resetTimer;
	document.onkeypress=resetTimer;
}
else
{
	window.onmousemove=resetTimer;
	window.onkeypress=resetTimer;
}
function resetTimer()
{
	clearTimeout(timer);
	timer=setTimeout("pageTimeout()",5000);
}
function pageTimeout()
{
	window.location.replace("http://www.google.co.uk") ;
}
window.onload=resetTimer;
</script>
__________________
Sinthetic - Alternative UK Hiphop: What's the worst that could happen?

"I'm going to become rich and famous when I invent a device that allows you to stab people in the face over the internet"



Reply With Quote
  #3  
Old November 16th, 2005, 03:43 AM
skelterweb skelterweb is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Nov 2005
Posts: 13 skelterweb User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 6 h 50 m 45 sec
Reputation Power: 0
i made the modification and it works fine, thanks...now a bigger prob. is it possible to made a password type in the prompt window? instead appears the letter, number it appears * or any other symbol?

thnaks

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingJavaScript Development > Prompt window


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway