1

I am trying to set the scope of a cookie for only the default web page on my web application using the HttpCookie.Domain and HttpCookie.Path. The page is named "default.aspx". Problem is, it is set as the default web page so the user goes to "mywebsite.com" in which the path is "/". So the browser does not see the name of the page and therefore doesn't find the cookie if Path is set to "/default.aspx" subsequently.

Is there a trick to get around that or am I stuck with just using a cookie that will be sent back and forth for all pages in the site?

4

0 回答 0