登陆后在后台存储了cookieHttpCookie cookie = new HttpCookie("User");
cookie.Values.Add("Grade", System.Web.HttpUtility.UrlEncode(ds.Tables[0].Rows[0]["Member_grade"].ToString()));
cookie.Values.Add("Guid", ds.Tables[0].Rows[0]["mem_Guid"].ToString());
cookie.Values.Add("Name", HttpUtility.UrlEncode(ds.Tables[0].Rows[0]["mem_UserName"].ToString()));
cookie.HttpOnly = true;
HttpContext.Current.Response.AppendCookie(cookie);
HttpContext.Current.Response.Redirect("index.aspx");
但是点击安全退出之后再次点击首页 cookie没有清楚用户名还可以看到我的安全退出按钮是一个 <a href="#">安全退出</a> 是在一个静态页面里面 怎样才可以点安全退出清理cookie呢??
cookie.Values.Add("Grade", System.Web.HttpUtility.UrlEncode(ds.Tables[0].Rows[0]["Member_grade"].ToString()));
cookie.Values.Add("Guid", ds.Tables[0].Rows[0]["mem_Guid"].ToString());
cookie.Values.Add("Name", HttpUtility.UrlEncode(ds.Tables[0].Rows[0]["mem_UserName"].ToString()));
cookie.HttpOnly = true;
HttpContext.Current.Response.AppendCookie(cookie);
HttpContext.Current.Response.Redirect("index.aspx");
但是点击安全退出之后再次点击首页 cookie没有清楚用户名还可以看到我的安全退出按钮是一个 <a href="#">安全退出</a> 是在一个静态页面里面 怎样才可以点安全退出清理cookie呢??
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货