如何获取浏览器中cookie的值
HttpCookiecookie=FormsAuthentication.GetAuthCookie(userId,false);FormsAuthenticationT...
HttpCookie cookie = FormsAuthentication.GetAuthCookie(userId, false); FormsAuthenticationTicket ticket = FormsAuthentication.Decrypt(cookie.Value); FormsAuthenticationTicket newTicket = new FormsAuthenticationTicket(ticket.Version, userId , ticket.IssueDate, ticket.Expiration.AddMinutes(300), ticket.IsPersistent, model.RoleName); cookie.Value = FormsAuthentication.Encrypt(newTicket); Context.Response.Cookies.Add(cookie);如何获取
展开
2个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询