Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 1 of 1
07-29-2014, 08:48 PM #1
- Join Date
- Aug 2010
- Southern Oregon
- Thanked 1 Time in 1 Post
Trouble with setting cookie path values correctly
I have had frustrating difficulty with setting the path value for cookies so they
can be read by the server scripts (in this case php which also sets cookies)
Since the virtual root of a site is / indicating the document root of the site
it seems that the path value / would allow any script in the site to read the
cookie, not just the script in the directory that set the cookie.
So can someone give me a good primer on setting path values for cookies?
I recentlty had to switch hosting services and had to up date code to reflect
the new file structure of the site. I had the path value of a cookie set to
/public_html (the document root dir) and changed it to /httpdocs for the
new site and it is not being cleared at the end of a login session.
THanks for time and attention
update: I seem to have solved the problem. with the help of Wikipedia and the php online documentation.
Last edited by anotherJEK; 07-30-2014 at 06:50 AM.