when i set a cookie in the root folder for example, the cookie doesnt work for any oother folder. Aso when i try to delete a cookie set in the root in a different folder, the cookie will still work.
Will setting a domain for every cookie solve this?
cookie domain
Started by Av-, Jan 20 2006 05:48 PM
2 replies to this topic
#1
Posted 20 January 2006 - 05:48 PM
#2
Posted 20 January 2006 - 05:52 PM
nevermind,
i shouldve looked at php.net/setcookie before i posted this thread.
so like this it will work on my whole domain?
i shouldve looked at php.net/setcookie before i posted this thread.
so like this it will work on my whole domain?
setcookie("CoOoOokie", $variable, 3600, "/");
#3
Posted 21 January 2006 - 03:30 PM
After the path parameter ("/") you should set the domain. Use ".domain.com" for it to apply to the domain and every subdomain. Use "www.domain.com" for it to only apply to the www subdomain.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users
