php.ini + session config

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
nigma
DevNet Resident
Posts: 1094
Joined: Sat Jan 25, 2003 1:49 am

php.ini + session config

Post by nigma »

I am having trouble setting up sessions to work in php. Now I have tried a few things(with the help of people at this forum) like setting the save_path and sofourth. But when I first had this problem I had 8 error messages everytime I tried to start a session, now I only have 2. Here they are:

Warning: Unknown(): open(C:\Program Files\Apache2\sessions\\sess_d48d15459bcc6f40d1ffe2ac679eb9e5, O_RDWR) failed: No such file or directory (2) in Unknown on line 0

Warning: Unknown(): Failed to write session data (files). Please verify that the current setting of session.save_path is correct (C:\Program Files\Apache2\sessions\) in Unknown on line 0

Thanks for all help and advice provided.
Last edited by nigma on Wed Feb 18, 2004 9:41 pm, edited 2 times in total.
gbow
Forum Newbie
Posts: 12
Joined: Wed Feb 18, 2004 6:28 am

Post by gbow »

hi

dunno if you managed to sort this yet
i am no expert but it would seem to me that the directory where your php.ini is set to save the sessions cannot be found

this is set here
session.save_path = "C:\Program Files\Apache2\sessions"

i see you have already messed with savepath (your comments in your post) but all i know is that the default is set to /tmp and it works fine for me

maybe you could try this?
if you already have then i apologise
User avatar
liljester
Forum Contributor
Posts: 400
Joined: Tue May 20, 2003 4:49 pm

Post by liljester »

make sure the sessions dir exists (C:\Program Files\Apache2\sessions) then check permissions on that directory. may be easier to create a root level directory "c:\sessions", and set proper permissions
and then set:
session.save_path = /sessions
Post Reply