Closed am05mhz closed 4 years ago
@am05mhz how did you solve this?
@daniluk4000 its a bad practice to use same cookie name on main domain .domain.tld
and subdomain sub.domain.tld
, if you want to use same name, you need to set the cookie at main domain level, even when you are on subdomain, this way you can access the cookie from any subdomain
get
will follow browser's value, depends on current url on which subdomain, that is why no domain opts on get
@daniluk4000 its a bad practice to use same cookie name on main domain
.domain.tld
and subdomainsub.domain.tld
, if you want to use same name, you need to set the cookie at main domain level, even when you are on subdomain, this way you can access the cookie from any subdomain
get
will follow browser's value, depends on current url on which subdomain, that is why no domain opts onget
Did you follow those rules? right now I'm setting all the cookies as the "domain.com" but I want to access them from the "subdomain.domain.com" I also try to set the cookies domain with ".domain.com" with no luck I can't access them from the subdomain.
I have no much control on the cookies because they are set during proxy calls
there is domain opts for
set
andremove
, but why not onget
?for example i set a cookie
'abcd'
with'.example.com'
domain, with value 123 then i set another cookie with same name for domainsub.example.com
and value 987how do i get the first or second cookie?