Re: header("Location: page.php") not redirecting
| From: | Chris Shiflett | Date: | Mon, 01 Dec 2003 22:13:54 +0000 |
| Subject: | Re: header("Location: page.php") not redirecting | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-171509@lists.php.net to get a copy of this message | ||
--- rogue <rogue@mail.rightcode.net> wrote:
> $redirect = "http://" .
> $_SERVER['HTTP_HOST'] .
> "/cm/clients/viewclient.php?id={$_REQUEST['id']}&foo=bar";
> error_reporting(E_ALL);
> echo "Location: $redirect";
> header("Location: $redirect");
I meant to try using a full URL first, then use echo if it still doesn't
work. :-) This shouldn't work as it is, because you have output prior to
your header call.
But, since you already tried this, what did the echo output? Did it look
correct? Comment that out, and see what happens.
Hope that helps.
Chris
=====
Chris Shiflett - http://shiflett.org/
PHP Security Handbook
Coming mid-2004
HTTP Developer's Handbook
http://httphandbook.org/