dev Posted June 26, 2008 Share Posted June 26, 2008 Hi,I was trying to set cookie domain property to my domain name, say www.abc.comI am trying this because i want to access this cookie for my entire website usage. Cookie is created by one of my subdomain (say. test.abc.com) so theoritically the cookie name will be cookie:name@test.abc.com/ and hence this cookie will be accessible only the test.abc.com; so i tried to setup cookie domain property to cookie:name@www.abc.com/ so that other subdomains can also access it but its not working.This is the code i am using:---------Line1: Response.Cookies("TP")=variablesLine2: Response.Cookies("TP").Domain = "www.abc.com"Line3: Response.Cookies("TP").Expires=now()+1---------Without Line2 the cookie works just fine with default domain name. can anyone know whats wrong and how the problem can be solved?with thanks Link to comment Share on other sites More sharing options...
justsomeguy Posted June 26, 2008 Share Posted June 26, 2008 Use ".abc.com" as the domain, it will apply to all subdomains. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.