

function SetCookie(Name, Value, Days) {
    var e = '';
	if (Days) {
		var date = new Date();
		date.setTime(date.getTime() + (Days*24*60*60*1000));
		e = '; expires=' + date.toGMTString();
	}
	document.cookie = Name + '=' + escape(Value) + e;
}
function GetCookie(Name) {
	var n = Name + '=';
	var c = document.cookie.split(';');
	for(var i=0; i < c.length; i++) {
		var e = c[i];
		while (e.charAt(0) == ' ') e = e.substring(1, e.length);
		if (e.indexOf(n) == 0) return e.substring(n.length, e.length);
	}
	return null;
}
function RemoveCookie(Name) {
	SetCookie(name, ' ', -1);
}