保存:
Response.Cookies["OpenID"].Value = wxobj.openid;
Response.Cookies["NickName"].Value = HttpUtility.UrlEncode(wxobj.nickname);
Response.Cookies["headimgurl"].Value = headimgurl;
取出 if (HttpContext.Current.Request.Cookies["NickName"] != null)
{
AcceptName = HttpUtility.UrlDecode(HttpContext.Current.Request.Cookies["NickName"].Value.ToString());
// AcceptName = HttpContext.Current.Request.Cookies["NickName"].Value.ToString();
}
if (HttpContext.Current.Request.Cookies["OpenID"] != null)
{
userName = HttpContext.Current.Request.Cookies["OpenID"].Value.ToString();
}
HttpContext.Current.Response.Cookies["u"]["p"] = phone;
string LoginName = HttpContext.Current.Request.Cookies["u"]["p"].ToString(); ;
时间: 2024-10-13 16:28:48