if(!sitelang) var sitelang = '';
if(!siteroot) var siteroot = './';

function at_getWinX() {
	var size = 0;
	if(window.innerWidth) {
		size = window.innerWidth;
	} else if(document.documentElement && document.documentElement.clientWidth) {
		size = document.documentElement.clientWidth;
	} else if(document.body && document.body.clientWidth) {
		size = document.body.clientWidth;
	} else {
		size = screen.width;
	}
	return size;
}

function at_getWinY() {
	var size = 0;
	if(window.innerHeight) {
		size = window.innerHeight;
	} else if(document.documentElement && document.documentElement.clientHeight) {
		size = document.documentElement.clientHeight;
	} else if(document.body && document.body.clientHeight) {
		size = document.body.clientHeight;
	} else {
		size = screen.height;
	}
	return size;
}

function MM_openBrWindow(theURL,winName,features) {
	window.open(theURL,winName,features);
}

function at_openwindow(theurl,winname,w,h,features) {
		leftposition = (at_getWinX() - w) / 2;
		topposition = (at_getWinY() -h ) / 2;
		settings = 'height='+h+',width='+w+',top='+topposition+',left='+leftposition;
		if(features != '') {
			settings = settings + ','+features;
		}
		window.open(theurl,winname,settings);
}

function at_hidestatus() {
	window.status=''
	return true
}

function at_stoperror() {
	return true;
}

if(sitelang=="vietnamese") {
	document.write('<script type="text/javascript" src="' + siteroot + 'js/avim.js"></script>');
}

window.onerror = at_stoperror;
document.onmousemove = at_hidestatus;
document.onmouseover=at_hidestatus;
document.onmouseout=at_hidestatus;
