中文COOKIES防止乱码

来源:互联网 发布:铁货架 淘宝 编辑:程序博客网 时间:2024/04/30 17:49


Response.Cookies["cxxx"]["xxxx"] = adm1.namer;


//中文COOKIS 用HttpContext.Current.Server.UrlDecode解码,用下面语句编码


Response.Cookies["xxxx"]["xxxxx"] = HttpContext.Current.Server.UrlEncode(adm1.zhanghao);


Label1.Text = HttpContext.Current.Server.UrlDecode(Request.Cookies["xxx"]["zxxxo"]);


this.ClientScript.RegisterStartupScript(typeof(string), "alert", "alert('该文件夹内已存在同名的文件,请重新输入!');", true);


del = "<a href=delfile.aspx?fid=" + infolist.Tables[0].Rows[i]["f_id"].ToString() + "  onclick='return confirm(\"删除后将无法恢复!真的要删除?\");'>删除</a>";

0 0