Re: Re: Problem: lost session id when htaccess'ing.

From: Date: Wed, 19 Sep 2001 01:41:00 +0000
Subject: Re: Re: Problem: lost session id when htaccess'ing.
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-67775@lists.php.net to get a copy of this message
On Tue, 18 Sep 2001, Chris Lee wrote: > - you have cookie support on or off ? > - you using any header redirects ? (you have to manually add the SID to > URI's) Sorry for the lenght of this mail. PHP compiled with --enable-trans-id, so PHP adds SID to the URL. session.use_cookies = 0, session.referer_check =, session.auto_start = 1, session.name = SID Having this doc tree: /index.html | \___ systems/index.html |___ .htaccess --- /index.html --- <!-- where systems/ is htaccess protected, using a hacked version of mod_auth_mysql --> <!-- here PHP attaches the first SID (supposed to be taken by systems/index.html automagically, as session.auto_start = 1 --> <a href="systems/index.html">Enter</a> --- /index.html --- Now: --- systems/index.html --- <?php if ($HTTP_SESSION_VARS[inside] != 1) // register all the session variables, etc. ?> <frameset cols="100,*"> <frame src="menu.html"> <!-- here php attaches the *new* SID, not the --> <!-- passed from /index.html --> <frame src="main.html"> </frameset> --- systems/index.html --- Do I need to use the SID constant with session_id() to set the first session ID? (I mean, the one from the href who taked me to the systems/ directory). Thanks, Rodolfo.

« previous php.general (#67775) next »