RE: [PHP] PHP not remembering sessions
| From: | Vail, Warren | Date: | Thu, 23 Oct 2003 21:05:35 +0000 |
| Subject: | RE: [PHP] PHP not remembering sessions | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-167363@lists.php.net to get a copy of this message | ||
Sounds to me like the browser you are using has cookies disabled?
Curious, do you see a parameter in your php.ini labeled session.name?
In fact, why don't you compare your setup to the following from a foxserv
installation of sessions;
Directive Local Value Master Value
session.auto_start Off Off
session.cache_expire 180
180
session.cache_limiter nocache nocache
session.cookie_domain no value no
value
session.cookie_lifetime 0 0
session.cookie_path / /
session.cookie_secure Off Off
session.entropy_file no value no value
session.entropy_length 0 0
session.gc_maxlifetime 1440 1440
session.gc_probability 1 1
session.name PHPSESSID PHPSESSID
session.referer_check no value no value
session.save_handler files files
session.save_path C:\FoxServ\sessiondata
C:\FoxServ\sessiondata
session.serialize_handler php php
session.use_cookies On On
session.use_trans_sid 1 1
I have had people (who didn't know what they were doing) change values like
cookie_lifetime and cause sessions to look like they had timed out after the
cookie was distroyed by the browser.
hope this gets you back and running.
Warren
-----Original Message-----
From: Golawala, Moiz M (IndSys, GE Interlogix)
[mailto:Moiz.Golawala@ge.com]
Sent: Thursday, October 23, 2003 1:49 PM
To: Vail, Warren; Curt Zirzow; php-general@lists.php.net
Subject: RE: [PHP] PHP not remembering sessions
Hi Warren,
Ahh.. now i know what you mean by save handler routines.. I don't have any
in any of my php files.
yes, the save_path was pointing to the place where I have the web files
stored. I can see the session files in that directory. I have tried to point
to another directory too. But I have the same problem. Each time I do a
session start on a page, I have a new session file. The first one has data
in it because I add the data to the session on the page. The second session
file is empty. Infact if I have an <?echo SID;?> on each of the 2 pages, I
see different session Ids.
You are correct.. I didn't think about a user getting to the session files.
modify the php.ini file to save the session files to a more secure location.
> Regards,
> Moiz Golawala
> Casi-Rusco, a GE Interlogix Company
> 791 Park Of Commerce Blvd., Boca Raton, FL 33487 *
> moiz.golawala@casi-rusco.com *
> 561-912-5972 * 561-912-1650 *
>
-----Original Message-----
From: Vail, Warren [mailto:Warren.Vail@schwab.com]
Sent: Thursday, October 23, 2003 4:42 PM
To: Golawala, Moiz M (IndSys, GE Interlogix); Curt Zirzow;
php-general@lists.php.net
Subject: RE: [PHP] PHP not remembering sessions
while this doesn't mean that save handler routines are not used, it provides
some clues.
Does the directory pointed to by the session.save_path contain session files
(they will usually have an encrypted filename)?
save handler routines are actually defined in your php files, usually
dynamically, possibly in a common include file; and they override but do not
change the settings in your php.ini file.
http://us4.php.net/manual/en/function.session-set-save-handler.php
The directory pointed to, looks suspicious since it appears that it may be
in the web space area (accessible to http:), if someone can browse that
directory with a browser, all kinds of good things might be found inside
sessions??? if your http.conf file (for apache) points to something other
than htdocs as the web root, you may be ok.
Warren
-----Original Message-----
From: Golawala, Moiz M (IndSys, GE Interlogix)
[mailto:Moiz.Golawala@ge.com]
Sent: Thursday, October 23, 2003 1:31 PM
To: Vail, Warren; Curt Zirzow; php-general@lists.php.net
Subject: RE: [PHP] PHP not remembering sessions
This is what is defined in the php.ini file for save handler routines.. I am
newbie, I left it with default values:
session.save_handler = files
session.save_path = c:/Program Files/Apache Group/Apache2/htdocs/Alarms/
thanks
moiz
-----Original Message-----
From: Vail, Warren [mailto:Warren.Vail@schwab.com]
Sent: Thursday, October 23, 2003 4:27 PM
To: 'Curt Zirzow'; php-general@lists.php.net
Subject: RE: [PHP] PHP not remembering sessions
are you using "session save handler" routines?
If not make sure you have a "/tmp" directory on your server, in fact you can
check phpinfo() to find out what the session save directory is (provided you
are not using save handler routines).
good luck
Warren Vail
-----Original Message-----
From: Curt Zirzow [mailto:php-general@zirzow.dyndns.org]
Sent: Thursday, October 23, 2003 1:30 PM
To: php-general@lists.php.net
Subject: Re: [PHP] PHP not remembering sessions
* Thus wrote Daniel Guerrier (dan_guerrier@yahoo.com):
> Use
> $_SESSION['var']
>
> instead of
>
> $_SESSION["var"]
This doesn't matter.
Curt
--
"My PHP key is worn out"
PHP List stats since 1997:
http://zirzow.dyndns.org/html/mlists/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php