function GetObject(obj){
	isNS4 = (document.layers) ? true : false;
	isIE4 = (document.all && !document.getElementById) ? true : false;
	isIE5 = (document.all && document.getElementById) ? true : false;
	isNS6 = (!document.all && document.getElementById) ? true : false;

	if (isNS4){
	   elem = document.layers[obj];
	}
	else if (isIE4) {
	   elem = document.all[obj];
	}
	else if (isIE5 || isNS6) {
	   elem = document.getElementById(obj);
	}

	return elem;
}

		function setCookie(name, value, expires, path, domain, secure)
		{
			document.cookie= name + "=" + escape(value) +
				((expires) ? "; expires=" + expires.toGMTString() : "") +
				((path) ? "; path=" + path : "") +
				((domain) ? "; domain=" + domain : "") +
				((secure) ? "; secure" : "");
		}

		/**
		 * Gets the value of the specified cookie.
		 *
		 * name  Name of the desired cookie.
		 *
		 * Returns a string containing value of specified cookie,
		 *   or null if cookie does not exist.
		 */
		function getCookie(name)
		{
			var dc = document.cookie;
			var prefix = name + "=";
			var begin = dc.indexOf("; " + prefix);
			if (begin == -1)
			{
				begin = dc.indexOf(prefix);
				if (begin != 0) return null;
			}
			else
			{
				begin += 2;
			}
			var end = document.cookie.indexOf(";", begin);
			if (end == -1)
			{
				end = dc.length;
			}
			return unescape(dc.substring(begin + prefix.length, end));
		}

function openNewWindow(url, name, width, height)
{  
	var w = 480, h = 340;
	if (document.all || document.layers) {
	   w = screen.availWidth;
	   h = screen.availHeight;
	}
	var leftPos = (w-width)/2, topPos = (h-height)/2;

	
	popupWin = window.open(url, name, 'width=' + width + ',height=' + height + ',top=' + topPos + ',left=' + leftPos + ', resizable=no,scrollbars=yes,status=no,location=no,toolbar=no,menubar=no')
}
