var width=window.screen.width, height=window.screen.height,
	resized_width  = Math.floor(width * 80 / 100), //rounded down to int
	resized_height = Math.floor(height * 80 / 100);
var centerLeft = (width - resized_width) / 2;	//left position to center the popup
var centerTop  = (height - resized_height) / 2;
var centerLeft = (width - resized_width) / 2;	//left position to center the popup
var centerTop  = (height - resized_height) / 2;
//var currentX=10, currentY=10;

function OpenWnd(source) //never use var here
{
		OpenNewWindow = window.open(source, "title", "WIDTH="+resized_width+",HEIGHT="+resized_height+",left="+centerLeft+",top=0,screenX=0,screenY=0,titlebar=1,menubar=0,resizable=1,scrollbars=1,location=0,hotkeys=1,status=1,toolbar=0,dependent=1", //screenX and screenY are for Netscape and left and top for Explorer
		false);	//indicates that the current history entry should not be replaced. 
		//But false IS THE DEFAULT, it's here just for illustrating
		OpenNewWindow.focus();		
}

function OpenForms(source)
{
		OpenForm = window.open(source,"form","titlebar=yes,resizable=yes,scrollbars=yes", true);
		OpenForm.focus();
}

function OpenWndSized(source, width, height)
{
	width += 10;
	height += 15;
	var screenWidth = window.screen.width;
	var centerLeft = (screenWidth - width) / 2;
	OpenNewWindow = window.open(source,"","WIDTH="+width+",HEIGHT=" + height+",left="+centerLeft+",top=0,titlebar=0,menubar=0,resizable=1,scrollbars=0," + "location=0,hotkeys=0,status=0,toolbar=0,dependent=1");
		OpenNewWindow.focus();	
}
