Setcookies and redirect
| From: | Andrea Resmini | Date: | Sat, 02 Dec 2000 14:52:01 +0000 |
| Subject: | Setcookies and redirect | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-28364@lists.php.net to get a copy of this message | ||
Talking about cookies and headers
>> doesn't work because you can't set any http headers before a redirect
>> header.... as far as i know ....
>Correct. But i have observed that sometimes it doesn't work even though no
>output has been sent to the client.
I observed a related behaviour on IE on Windows and Opera (Linux and
Windows). Mozilla M18 Linux seems to have an herratic attitute towards
this: sometimes it works, sometimes it doesn't.
In brief: while Netscape 4.75 on Linux sets the cookie and redirects
flawlessly (I use a technique similar to the one described in your
pseudo-function: a script with no output is called, sets the cookie and
redirects back), the other browsers actually do not redirect, but the
cookie gets set (although Opera does not warn me of the cookie even with
warnings on. Doh.), since reloading the page manually shows the change.
I must admit that I'm a bit at loss here, and I am myself mightily
interested in any further details on this matter.
--
Andrea Resmini
a.resmini@ogcs.com
hypermedia development, OGCs.com
http://www.ogcs.com