Re: Problems with Sessions?

From: Date: Fri, 07 Sep 2001 12:50:11 +0000
Subject: Re: Problems with Sessions?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-66402@lists.php.net to get a copy of this message
On the first page of a session, PHP attempts to set a PHPSESSID cookie. It won't get that cookie back until you reload the page or load another page, so it has no way of knowing on the first page whether or not the browser accepted the cookie. So, it adds the PHPSESSID string to all of your local links in order to maintain the session. When you load another page during the same session and your browser sends the cookie back, PHP sees that cookies are working, so it no longer modifies your links. If you want to disable this behavior, you can add this line to your php.ini file: session.use_trans_sid = 0 This will cause sessions to not work on browsers where cookies are disabled. Doug Granzow dig@cynosure.net "Tim" <spaced@connect.ab.ca> wrote in message news:20010906193008.20087.qmail@pb1.pair.com... > When I first browse to a site on my LAN, I get links with URLs that look > like this: > > chat/?PHPSESSID=f3d149f79f5196bd709fb3c256dbb3d8 > > after a refresh, the whoe PHPSESSID goes away. > > Wondered if there was some setting in php.ini that I've overlooked? > > I'm running PHP4 with Apache on an Unstable Debian box. > > Any help would be appreciated :-) > >

« previous php.general (#66402) next »