
function xlaALSprecheck(){
	if ((document.body && typeof(document.body.innerHTML)) != 'undefined'){
		xlaALSrequest();
	} else {
		alert('Sorry, but your browser does not support several features of this system.');
	}
}
function xlaALSrequest(){
	var w = 640, h = 480;
	if (document.all || document.layers) {
	   w = screen.availWidth;
	   h = screen.availHeight;
	}
	document.cookie="xlaALSuser=email=" + escape(document.askQ.email.value) + "&msg=" + escape(document.askQ.question.value);
	var leftPos = (w-600)/2, topPos = (h-400)/2;
	xlaALSwindow=window.open("http://www.matrixusa.us/livechat/UserPreChat.asp?ref=","ALSRoom","toolbar=0,location=0,status=0,menubar=0,scrollbars=1,resizable=1,width=600,height=400,top=" + topPos + ",left=" + leftPos);
	xlaALSwindow.focus();
}

function xlaALScheckstatus(){
	var nt=String(Math.random()).substr(2,10);
	document.getElementById("xlaALSstatusimg").src='http://www.matrixusa.us/livechat/als.asp?getstatus=1&nt=' + nt;
	setTimeout("xlaALScheckstatus();", 10000);
}

function limitText(limitField, limitCount, limitNum) {
	if (limitField.value.length > limitNum) {
		limitField.value = limitField.value.substring(0, limitNum);
	} else {
		limitCount.value = limitNum - limitField.value.length;
	}
}

document.write("<a href='contactus.htm'><img src='http:\/\/www.matrixusa.us\/livechat\/files\/offline.gif' border=0 id=xlaALSstatusimg><\/a>");
xlaALScheckstatus();