Re: Redirect browser to another URL?
| From: | Cam Dunstan | Date: | Wed, 27 Nov 2002 10:44:07 +0000 |
| Subject: | Re: Redirect browser to another URL? | ||
| References: | 1 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-17160@lists.php.net to get a copy of this message | ||
Jack,
here is another quick and dirty function to stick in your library, yet
another way to redirect from anywhere in your script
function redirect($url){
echo
"<script>window.location.replace(\"".$url."\")</script>";
}
usage:
blah
blah
redirect("any_url");
exit;
>
> -----Original Message-----
> From: Jack Kelly Dobson [mailto:jdobson@tcgcorp.net]
> Sent: Tuesday, November 26, 2002 2:43 PM
> To: php-windows@lists.php.net
> Subject: [PHP-WIN] Redirect browser to another URL?
>
>
> Hello,
>
> Anyone know how to have a script re-direct the browser to a URL cleanly?
>