Jump to content

Display and redirect!


mccanna

Recommended Posts

put this on the bottom of tha page you want displayed for xx seconds.

$sec = 5; // number of seconds until redirect
header("Refresh: $sec; url=http://www.yoururl.php");



Snowdog


[!--quoteo(post=357314:date=Mar 22 2006, 10:26 AM:name=AMcC)--][div class=\'quotetop\']QUOTE(AMcC @ Mar 22 2006, 10:26 AM) [snapback]357314[/snapback][/div][div class=\'quotemain\'][!--quotec--]
Is it possible to display a php page for 3 or 4 seconds and then redirect the user back to the main menu page? If so, could you give a simple example or suggest an appropriate tutorial?
[/quote]
Link to comment
https://forums.phpfreaks.com/topic/5507-display-and-redirect/#findComment-19718
Share on other sites

Perfect! Thanking you!
[!--quoteo(post=357364:date=Mar 22 2006, 08:04 PM:name=snowdog)--][div class=\'quotetop\']QUOTE(snowdog @ Mar 22 2006, 08:04 PM) [snapback]357364[/snapback][/div][div class=\'quotemain\'][!--quotec--]
put this on the bottom of tha page you want displayed for xx seconds.

$sec = 5; // number of seconds until redirect
header("Refresh: $sec; url=http://www.yoururl.php");
Snowdog
[/quote]
Link to comment
https://forums.phpfreaks.com/topic/5507-display-and-redirect/#findComment-21119
Share on other sites

[!--quoteo(post=357314:date=Mar 22 2006, 10:26 AM:name=AMcC)--][div class=\'quotetop\']QUOTE(AMcC @ Mar 22 2006, 10:26 AM) [snapback]357314[/snapback][/div][div class=\'quotemain\'][!--quotec--]
Is it possible to display a php page for 3 or 4 seconds and then redirect the user back to the main menu page? If so, could you give a simple example or suggest an appropriate tutorial?
[/quote]


Yes, you can use a meta refresh

[code]
<meta http-equiv="Refresh" content="3; URL=http://www.yourdomain.com/yourpage.php" >
[/code]

where 3 is the amount of seconds you want to display the page for.

Seamless

seems like i need to refresh my page more :P
Link to comment
https://forums.phpfreaks.com/topic/5507-display-and-redirect/#findComment-21122
Share on other sites

[!--quoteo(post=358812:date=Mar 27 2006, 10:24 AM:name=AMcC)--][div class=\'quotetop\']QUOTE(AMcC @ Mar 27 2006, 10:24 AM) [snapback]358812[/snapback][/div][div class=\'quotemain\'][!--quotec--]
Perfect! Thanking you!
[!--quoteo(post=0:date=Mar 22 2006, 08:04 PM:name=snowdog)--][div class=\'quotetop\']QUOTE(snowdog @ Mar 22 2006, 08:04 PM)[/div][div class=\'quotemain\'][!--quotec--]
put this on the bottom of tha page you want displayed for xx seconds.

$sec = 5; // number of seconds until redirect
header("Refresh: $sec; url=http://www.yoururl.php");
Snowdog[/quote]
[/quote]
Make sure you use the header function before the output of any text/html otherwise PHP will report back a warning error and your script wont run.
Link to comment
https://forums.phpfreaks.com/topic/5507-display-and-redirect/#findComment-21129
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.