【csdn史上最纠结的问题】ie,火狐读不出,opera和Google却能读出cookie子键集合 都纠结一年多了,才发现用Google浏览器是正常的~~~~~~~ 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 ie,火狐读不出,opera和Google却能读出cookie子键集合,并能在用户登录状态正常显示购物车里的商品 你可以把能读出来的cookie的内容分析下,看是不是有什么特殊的格式 额..这么枯燥的帖子,我都没看多少,原来cookie内容贴出来了的.. Presto有着天生的优势,页面的全部或者部分都能够在回应脚本事件时等情况下被重新解析。此外该内核在执行Javascrīpt的时候有着最快的速度,根据在同等条件下的测试,Presto内核执行同等Javascrīpt所需的时间仅有Trident和Gecko内核的约1/3(Trident内核最慢,不过两者相差没有多大)。 这个问题我解决了错误的是有注释的 正确是没有注释的/// <summary> /// 将要购买的商品信息写入Cookies /// </summary> public void WriteCookies(String ProductID, String Amount) { //HttpCookie aCookie = new HttpCookie("userInfo"); //aCookie.Values["userName"] = "patrick"; //aCookie.Values["lastVisit"] = DateTime.Now.ToString(); //aCookie.Expires = DateTime.Now.AddDays(1); //Response.Cookies.Add(aCookie); HttpCookie aCookie = new HttpCookie("ShoppingCart"); aCookie.Values["ProductID"] = ProductID; aCookie.Values["Amount"] = Amount; aCookie.Expires = DateTime.Now.AddDays(30); HttpContext.Current.Response.Cookies.Add(aCookie); //HttpContext.Current.Response.Cookies["ShoppingCart"]["ProductID"] = ProductID; //HttpContext.Current.Response.Cookies["ShoppingCart"]["Amount"] = Amount; //HttpContext.Current.Response.Cookies["ShoppingCart"].Expires = DateTime.Now.AddDays(60); } C# DropDownList 同值也刷新 如何用程序修改局域网中其它电脑的IP 从XML导入的dataset如何有选择的导入数据库 C# 读取word模板 处理动态级联 表格 问题? 如何安装我自己制作的服务程序? 怎样设置不能用鼠标拖拉改变Form的大小! 线程中的定时器如何结束 confirm对话框 服务意外终止怎么办?十万火急急急急急急急急急~~~!!!!!!!!!!!!!!!!!!!! 远程服务器返回错误: (404) 未找到。 文件操作高手进 C# System.Timers.Timer 方法起始时间问题
错误的是有注释的 正确是没有注释的
/// <summary>
/// 将要购买的商品信息写入Cookies
/// </summary>
public void WriteCookies(String ProductID, String Amount)
{
//HttpCookie aCookie = new HttpCookie("userInfo");
//aCookie.Values["userName"] = "patrick";
//aCookie.Values["lastVisit"] = DateTime.Now.ToString();
//aCookie.Expires = DateTime.Now.AddDays(1);
//Response.Cookies.Add(aCookie);
HttpCookie aCookie = new HttpCookie("ShoppingCart");
aCookie.Values["ProductID"] = ProductID;
aCookie.Values["Amount"] = Amount;
aCookie.Expires = DateTime.Now.AddDays(30);
HttpContext.Current.Response.Cookies.Add(aCookie); //HttpContext.Current.Response.Cookies["ShoppingCart"]["ProductID"] = ProductID;
//HttpContext.Current.Response.Cookies["ShoppingCart"]["Amount"] = Amount;
//HttpContext.Current.Response.Cookies["ShoppingCart"].Expires = DateTime.Now.AddDays(60); }