Skip to content

Stupid Cookie.Domain

Wed Mar 05 2003

I've spent about 1 1/2 hours trying to figure out why I couldn't get a persistent cookie set from codebehind in ASP.NET...I tried a lot of different things but of course not the correct solution. The domain. rrrrrrgh!

The worst part is that I sorted this out a few weeks ago, but since then it hasn't been a big issue, I've been letting the framework of each application handle the details of communicating with

Today I've been back on the originating app's side, making sure things are ready to get set, then I got all sweaty and whatnot about the 'cookie not being set properly', which was kind of true - my browser didn't think the code was coming from the same host. localhost != There's my 'D'oh!' for the day.

btw, it works still (whew!😃

💾 May the source be with you. v3.2.409