// JavaScript Documentfunction test(){alert("her")}

var win = null;
function 

openNewWindow(mypage,myname,w,h,scroll){
LeftPosition = (screen.width) ? (screen.width-w)/2 : 0;
TopPosition = (screen.height) ? (screen.height-h)/2 : 

0;
settings =
"height="+h+",width="+w+",top="+TopPosition+",left="+LeftPosition+",scrollbars=1,resizable"
alert(settings)
win = 

window.open(mypage,myname,settings)
if(win.window.focus){win.window.focus();}
}

function detecttd()
{
	if (document.getElementById("contenttd"))
	{
		alert(document.getElementById("contenttd").style.height)
	}
}

function getTDHeight(){
	contentTopDiv = document.getElementById("content_top")
	//contentBotDiv = document.getElementById("content_bottom")
	contentTop = getPixelsFromTop(contentTopDiv);
	//contentBottom = getPixelsFromTop(contentBotDiv);
	//contentHeight = contentBottom - contentTop;
	windowHeight = document.body.clientHeight;
	//alert(windowHeight +"/"+contentTop)
	document.getElementById("contentdiv").style.height = windowHeight-contentTop-40
	document.getElementById("menutd").style.height = windowHeight-250
	//alert(windowHeight-250)
}

function getPixelsFromTop(obj){
	objFromTop = obj.offsetTop;
	while(obj.offsetParent!=null) {
		objParent = obj.offsetParent;
		objFromTop += objParent.offsetTop;
		obj = objParent;
	}
	return objFromTop;
}



