var bw=new checkBrowser()

function setSize() {//IE only function
	w=document.all.sizer.clientWidth;
	h=document.all.sizer.clientHeight;
	lpos=Math.max(0,(w-760)/2);
	ypos=Math.max(0,(h-402)/2);
	document.write('<style type="text/css">#maincontent {position:absolute;left:'+lpos+'px;top:'+ypos+'px;width:760px;height:402px;}</style>');
}

function updateSize() {
	if (bw.ie) {w=document.all.sizer.clientWidth;h=document.all.sizer.clientHeight}
	if (bw.ns4) {w=window.innerWidth;h = window.innerHeight;}
	lpos=Math.max(0,(w-760)/2);
	ypos=Math.max(0,(h-402)/2);
	if (bw.ie) {document.all.maincontent.style.pixelLeft=lpos;document.all.maincontent.style.pixelTop=ypos;}
	if (bw.ns4) {document.maincontent.left=lpos;document.thepage.top=ypos;}
}

function handleResize() {
	if ((window.innerWidth!=lastWidth) || (window.innerHeight!=lastHeight)) {
		lastWidth=window.innerWidth;
		lastHeight=window.innerHeight;
		updateSize()
	}
}

if (bw.ie) {window.onresize=updateSize}
if (bw.ns4) {window.onresize=handleResize}