function FloatDiv(id, sx, sy)
{
	var ns = (navigator.appName.indexOf("Netscape") != -1);
	var d = document;
	var el=d.getElementById?d.getElementById(id):d.all?d.all[id]:d.layers[id];
	var px = document.layers ? "" : "px";
	window[id + "_obj"] = el;
	if(d.layers)el.style=el;
	el.cx = el.sx = sx;
	el.cy = el.sy = sy;
	el.sP=function(x,y){this.style.left=x+px;this.style.top=y+px;};
 
	el.floatIt=function()
	{
		var pX, pY;
		pX = (this.sx >= 0) ? 0 : ns ? innerWidth : 
		document.documentElement && document.documentElement.clientWidth ? 
		document.documentElement.clientWidth : document.body.clientWidth;
		pY = ns ? pageYOffset : document.documentElement && document.documentElement.scrollTop ? 
		document.documentElement.scrollTop : document.body.scrollTop;
		if(this.sy<0) 
		pY += ns ? innerHeight : document.documentElement && document.documentElement.clientHeight ? 
		document.documentElement.clientHeight : document.body.clientHeight;
		this.cx += (pX + this.sx - this.cx)/8;this.cy += (pY + this.sy - this.cy)/8;
		this.sP(this.cx, this.cy);
		setTimeout(this.id + "_obj.floatIt()", 50);
	}
	return el;
}
FloatDiv("webchatDiv", -230, -190).floatIt();

function openWindow(url, wname, width, height) {
window.open(url, wname, "height=" + height + ",width=" + width + "location = 0, status = 0, resizable = 0, scrollbars=0, toolbar = 0");
return true;
}

function doWebchat() {
//document.getElementById('myReferrer').value = document.referrer;
//document.getElementById('myDomain').value = document.domain;
document.webchat.myReferrer.value = document.referrer;
document.webchat.myDomain.value = document.domain;
openWindow('', 'webchatWin', 630, 590);
//document.getElementById('webchat').submit();
document.webchat.submit();

}

function doWebchatStart() {
document.webchat.myReferrer.value = document.referrer;
document.webchat.myDomain.value = document.domain;
openWindow('', 'webchatWin', 630, 590);
document.webchat.submit();
}

function closeChatWindow() {
document.getElementById('webchatDiv').style.visibility = 'hidden';
return false;
}



