Re: go to another file
| From: | Andreas Pour | Date: | Thu, 08 Jun 2000 00:28:03 +0000 |
| Subject: | Re: go to another file | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-1258@lists.php.net to get a copy of this message | ||
Hi,
If you have not already output any text, I would recommend a header
redirection:
header("Status: 302 Moved Temporarily");
header("Location: $url");
The drawback to using "Refresh" with a time of '0' is it effectively
disables your "back" button and keeps throwing you back to the redirect
page, which for me is enough to stop visiting a site. (If you use a
time of '1' this problem is solved, but then you get the page showing
for a while).
Ciao,
Andreas
stephan.schoell@chhos.mail.abb.com wrote:
>
> You can say (or code) somewhere in the head of your script:
>
> <?php if ($a == 1 ) { ?>
> <meta http-equiv="Refresh" content="0; URL=start.php3">
> <?php } else { ?>
> <meta http-equiv="Refresh" content="0; URL=quit.php3">
> <?php } ?>
>
> Take care of the quotation marks. They are set right in this example! This
> script will - depending on the value of $a immediately (0) reload the indicated
> file.
>
> HTH Steff
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net