kala-tamin Using the same cookie in two logins

Using the same cookie in two logins

I need your help

I've a MVC project that uses Jquery, where I've implemented a mechanism of "Remember Me" using cookies to save, clear and retrieve the login and password.

I also have two screens where the user does the login. I want that both logins manipulate the same cookie. I've got to implement it, but I've realized that each one has a different behaviour. I mean, the cookie's value I save in the first login is not the same than the value that retrieves the second login (when I open it). In other words, if I mark "remind me" on the first login, it isn't reflected on the second login and viceversa. What can I do to make that both of them manipulate and read the same values from the same cookie? Is it possible?

PS: For this situations I'm using the same web navigator: Firefox or IE.

Thanks in advance

Book suggestion on this DDD concept specific to ASP.NET MVC and JSON? [closed]


ASP.NET MVC 2 filling ViewModel data
Cookies are specific to the domain that creates them.

JQuery function fails when content loaded from Ajax form
If you are having two login screens,you need to have them under the same domain ( some thing like login.yourdomain.com if you have more than one domain).
How to check in ASP.NET MVC View if site is running on localhost or
ASP.Net MVC (1) - how can I pass JSON to view but not as separate ajax call

How do you globalise the ASP.Net forms authentication longinUrl for multiple languages?

Can i put ASP.NET in Js file?


how can i embed a powerpoint slide into a webpage
you can change the cookie domain, if you are using formsauthentication.

if not, you should also be able to change it.

. just take the same domain name for both sites.. http://msdn.microsoft.com/en-us/library/system.web.security.formsauthentication.cookiedomain.aspx. hth.

66 out of 100 based on 41 user ratings 1166 reviews