[»êÀÌ]´ÔÀÌ ³²±â½Å ±Û:
>function setcookie(name, value, expire)
>{
> var date = new Date();
> date.setDate(date.getDate() + expire);
> document.cookie = name + '=' + value + '; expires=' + date.toGMTString()+ ';
path=/';
>}
========================================
// http://members.ozemail.com.au/~dcrombie/cookie3.html
var bikky = document.cookie;
function getCookie(name) // use: getCookie("name")
{
var index = bikky.indexOf(name + "=");
if (index == -1) return null;
index = bikky.indexOf("=", index) + 1; // first character
var endstr = bikky.indexOf(";", index);
if (endstr == -1) endstr = bikky.length; // last character
return unescape(bikky.substring(index, endstr));
}
|