0
对MVC 3 IM一种新的,我只是发现这个实例项目中的MVC 2窗体身份验证Cookie MVC 3和MVC 2
FormsAuthenticationTicket authTicket = new FormsAuthenticationTicket(1,Username,DateTime.Now,DateTime.Now.AddMinutes(10), RememberMe, Username);
string encTicket = FormsAuthentication.Encrypt(authTicket);
this.Response.Cookies.Add(new HttpCookie(FormsAuthentication.FormsCookieName, encTicket));
,这对MVC 3示例项目
FormsAuthentication.SetAuthCookie(model.UserName, model.RememberMe);
我的问题是这是否具有相同的效果?我如何指定在mvc 3上的cookie的实况?
THX提前
thx很多@Daring – 2012-01-30 17:00:42