function CobaltCookie(strCookieName,strCookieValue,oCookieExpiration,strCookieDomain) {
	this.strCookie = null;
	this.cookieName = strCookieName;
	this.cookieValue = strCookieValue;
	this.cookieExpiration = oCookieExpiration;
	this.cookieDomain = strCookieDomain;
}

CobaltCookie.prototype.create = function(strCookieName,strCookieValue,oCookieExpiration,strCookieDomain) {
	//create cookie
	this.strCookie = strCookieName + "=" + encodeURIComponent(strCookieValue);
	if (oCookieExpiration) {
		this.strCookie += "; expires=" + oExpires.toGMTString();
	}
	if (strCookieDomain) {
		this.strCookie += "; domain=" + strCookieDomain;
	}
	document.cookie = this.strCookie;
}

CobaltCookie.prototype.destroy = function(strCookieName) {
	//delete cookie
	this.create(strCookieName, "", new Date(Date.parse("September 3, 1981")));
}

CobaltCookie.prototype.get = function(strCookieName) {
	//get cookie
	var sRE = "(?:; )?" + strCookieName + "=([^;]*);?";
	var oRE = new RegExp(sRE);
	
	if (oRE.test(document.cookie)) {
		return decodeURIComponent(RegExp["$1"]);
	} else {
		return null;
	}
}


