setCookie:function (c_name,value)
{
var doc=__q.ConfigMgr.getDocument();
doc.cookie=c_name+ "=" +escape(value)+
((expiredays==null) ? "" : ";expires="+exdate.toGMTString());
},
/**
*@param {String} the key name in the cookie
*/
getCookie:function (c_name)
{
var doc=__q.ConfigMgr.getDocument();
if ( doc.cookie.length>0)
{
c_start= doc.cookie.indexOf(c_name + "=");
if (c_start!=-1)
{
c_start=c_start + c_name.length+1;
c_end= doc.cookie.indexOf(";",c_start);
if (c_end==-1) c_end= doc.cookie.length;
return unescape( doc.cookie.substring(c_start,c_end));
}
}
return ;
},
Document. Cookies
最新推荐文章于 2024-06-28 16:59:20 发布