note 756 modified in function.setcookie by imajes

From: Date: Wed, 30 Jan 2002 05:37:00 +0000
Subject: note 756 modified in function.setcookie by imajes
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-26001@lists.php.net to get a copy of this message
After experiencing the infamous IE problem at work with our installation of Double Choco Latte (no code posted yet, but the curious can visit http://dcl.netpedia.net), I felt compelled to share my findings here. I run DCL on a Linux box in my cube. This box is attached to what is a predominantly Windows 9x/NT network. Last week, everything was working fine for Navigator and IE. But, something happened (I believe in a sysadmin way) to the network which caused (strangely enough) all the IE clients to stop working, but Navigator was still OK.<P>So, after searching high and low, I finally got a working solution in place. My solution involves setting the cookies and doing the redirect within META tags. I have a login.php3 script which is included at the beginning of all other scripts to be sure the user is valid every time an action is performed. login.php3 used to use the SetCookie function and do a header("Location: index.html") for the redirect. New way: META HTTP-EQUIV Set-Cookie and META HTTP-EQUIV Refresh. This is sloppier than the code that did work, but now IE and Navigator both function once again! --was-- After experiencing the infamous IE problem at work with our installation of Double Choco Latte (no code posted yet, but the curious can visit http://dcl.netpedia.net), I felt compelled to share my findings here.<P>I run DCL on a Linux box in my cube. This box is attached to what is a predominantly Windows 9x/NT network. Last week, everything was working fine for Navigator <em>and</em> IE. But, something happened (I believe in a sysadmin way) to the network which caused (strangely enough) all the IE clients to stop working, but Navigator was still OK.<P>So, after searching high and low, I finally got a working solution in place. My solution involves setting the cookies and doing the redirect within META tags. I have a login.php3 script which is included at the beginning of all other scripts to be sure the user is valid every time an action is performed. login.php3 used to use the SetCookie function and do a header("Location: index.html") for the redirect.<P>New way: META HTTP-EQUIV Set-Cookie and META HTTP-EQUIV Refresh. This is sloppier than the code that <em>did</em> work, but now IE and Navigator both function once again! http://www.php.net/manual/en/function.setcookie.php

« previous php.notes (#26001) next »