session is a session ID and it's stored as a cookie. cookies persist but when you setup php as a cgi it's a cgi appliaction - that means nothing persists in the context of the application running on the server. Unlike e.g. ASP where an application and a session has a persistance layer. WHen you make an application start point on IIS with ASP and have a global.asa file - this signifiies an application start point. You will notice that you can "unload" the application and set new application and new session variables each time you close the browser and staert a new session. With CGI - that's not the case. You need to manage your own session with cookies and the PHPSESSID cookie is where you start to do that. Alan Alan "B.A.T. Svensson" <B.A.T.Svensson@xxxxxxx> wrote in message news:D291F33C586C8E48B95C26F8C805513A01A3D934@xxxxxxxxxxxxxxxx > Are saying that session can not persist over different pages? > > -----Original Message----- > From: Alan McDonald > To: php-windows@xxxxxxxxxxxxx > Sent: 2004-02-16 10:57 > Subject: Re: header-session problem > > I'm afraid that's not what the seesion is all about. > The session is a unique value. It is assigned to a cookie if specified > in php.ini or is tagged along in all your URLs as a query string or $_GET > and has the name PHPSESSID by default unless you change it. > If you want to save something fro page 1 and retrieve it in page 3, then > you will need to do the same hing and store this value as a cookie. > $_COOKIE['cookiename'] will retrieve it. > But there are some provisos. You cannot assign a cookie value and set > header("Location.. etc on the same page, the cookie will not be set. You > need to set a cookie and let the page return to the browser. > That's with Windows environments anyway. > > Alan -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php