function resize(){  
var layers = document.getElementById("content");
var maintable = document.getElementById("tblInner");
var piston = document.getElementById("piston");
var htmlheight = document.body.parentNode.clientHeight;  
var windowheight = document.body.offsetHeight;
var NSwindowheight = window.innerHeight;
var htmlwidth = document.body.parentNode.clientWidth; 
var windowwidth = document.body.offsetWidth;
var cCell = document.getElementById("contentCell");
var ns = (document.layers)? true: false;
var ie = (document.all)? true: false;
var b = (ns)? "NS": (ie)? "IE" : " an out-dated browser!?!";
//alert("You are using " + b);
cCell.style.height = 540 + "px";
if(b!='IE'){
	piston.style.visibility = "hidden";
	switch (htmlwidth){
		case 1005 :
			piston_pos = 263;
			break;
		case 1024 :
			piston_pos = 200;
			break;
		case 1261 :
			piston_pos = 393;
			break;
		case 1280 :
			piston_pos = 393;
			break;
		case 1381 :
			piston_pos = 453;
			break;
		case 1400 :
			piston_pos = 453;
			break;
		case 1581 :
			piston_pos = 552;
			break;
		case 1600 :
			piston_pos = 552;
			break;
		case 1901 :
			piston_pos = 712;
			break;
		case 1920 :
			piston_pos = 712;
			break;
		case 2029 :
			piston_pos = 775;
			break;			
		case 2048 :
			piston_pos = 775;
			break;
		default:
			piston_pos = 315;
		}
	//alert("3. ff html width = " + htmlwidth + " Windowwidth = " + windowwidth);
	if ( htmlheight < windowheight ){
		layers.style.visibility = "hidden";
		document.body.style.height = htmlheight + "px";
		maintable.style.height = htmlheight + "px";
		cCell.style.height = htmlheight - 148 + "px";
		layers.style.height = htmlheight-152 + "px"; 
		//alert("1. NS height = " + NSwindowheight + " Windowheight = " + windowheight);
		layers.style.visibility = "visible";
		}  
	else{
		layers.style.visibility = "hidden";
		document.body.style.height = htmlheight + "px"; 
		maintable.style.height = htmlheight + "px";
		cCell.style.height = htmlheight - 148 + "px";
		layers.style.height = htmlheight-152 + "px";
		//alert("2. NS height = " + NSwindowheight + " Windowheight = " + windowheight);
		layers.style.visibility = "visible";
		}
	piston.style.left = piston_pos + "px";
	piston.style.visibility = "visible";
}
if(b=='IE'){
	piston.style.visibility = "hidden";
	//alert("3. win html width = " + htmlwidth + " Windowwidth = " + windowwidth);
	switch (htmlwidth){
		case 1003 :
			piston_pos = 253;
			break;
		case 1011 :
			piston_pos = 253;
			break;
		case 1259 :
			piston_pos = 383;
			break;
		case 1267 :
			piston_pos = 383;
			break;
		case 1379 :
			piston_pos = 443;
			break;
		case 1387 :
			piston_pos = 443;
			break;
		case 1579 :
			piston_pos = 542;
			break;
		case 1587 :
			piston_pos = 542;
			break;
		case 1899 :
			piston_pos = 702;
			break;
		case 1907 :
			piston_pos = 702;
			break;
		case 2027:
			piston_pos = 765;
			break;
		case 2035:
			piston_pos = 765;
			break;
		default:
			piston_pos = 100;
		}
	if ( htmlheight < windowheight ){
		layers.style.visibility = "hidden"
		document.body.style.height = htmlheight + "px";
		maintable.style.height = htmlheight + "px";
		cCell.style.height = htmlheight - 151 + "px";
		layers.style.height = htmlheight-153 + "px"; 
		//alert("1. htmlheight win = " + htmlheight + " Windowheight = " + windowheight);
		layers.style.visibility = "visible"
		}  
	else{
		layers.style.visibility = "hidden";
		document.body.style.height = htmlheight + "px"; 
		maintable.style.height = htmlheight + "px";
		cCell.style.height = htmlheight - 151 + "px";
		layers.style.height = htmlheight - 153 + "px";
		//alert("2. htmlheight win = " + htmlheight + " Windowheight = " + windowheight);
		layers.style.visibility = "visible";
		}
	piston.style.left = piston_pos + "px";
	piston.style.visibility = "visible";
}
}

function refresh()
{
    window.location.reload( true );
}