// JavaScript Document

var myWindow;
function openCenteredWindow(url,wd,ht) {
	if(wd == null)
	    var width = 500;
	else
		var width = wd;
	if(ht == null)		
	    var height = 300;
	else
		var height = ht;
    var left = parseInt((screen.availWidth/2) - (width/2));
    var top = parseInt((screen.availHeight/2) - (height/2));
    var windowFeatures = "width=" + width + ",height=" + height + 
        ",status,scrollbars=yes,menubar=1,resizable=yes,left=" + left + ",top=" + top + 
        ",screenX=" + left + ",screenY=" + top;
    myWindow = window.open(url, "subWind", windowFeatures);
}
