Jump to content

php transfer code problem


payam98

Recommended Posts

hi , i want one code for one of my pages , its php!
i want when someone came to my page after 2 sec it'll transfer to another page and after 7 sec came back to the first page and stop ! i mean only one time work each day for one user ! 
 
and i found one code from one of my friend , but this code it works but when i added it to my index.php its not work like that! its work but when it came back after 7 sec to the first page it'll not stop , it'll continue again !! please tell me what should i do?
 
this is the code for the first page: 
<?php
@session_start();
@ob_start();
$url='re2.php';
if(!$_SESSION["zegersot"])
{
$_SESSION["zegersot"]=true;
echo <<<HTML
<meta http-equiv="refresh" content="2; url= $url">
HTML;
}
?>
and this is for second page:
<meta http-equiv="refresh" content="7; url= re.php">

 

 

 

Link to comment
https://forums.phpfreaks.com/topic/275059-php-transfer-code-problem/
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.