Jump to content

Timer before refresh


graham23s

Recommended Posts

Hi Guys,

 

i use this piece of code to refresh to another page:

 

// javascript refresh //
  print('<script type="text/javascript">window.location = "account.php"</script>');

 

is there a way i can delay it by like 10 seconds or so to display a message before it refreshed?

 

thanks guys

 

Graham

Link to comment
https://forums.phpfreaks.com/topic/94331-timer-before-refresh/
Share on other sites

Hi Mate,

 

i did:

 

print('<script type="text/javascript">setTimeout("window.location=\"account.php\", 500")</script>');

 

but from what i can see it doesn't wait 5 seconds before refreshing it still does it pretty much straight away i thought 500 millisecs was 5 seconds am i wrong?

 

thanks mate

 

Graham

Link to comment
https://forums.phpfreaks.com/topic/94331-timer-before-refresh/#findComment-483690
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.