// JavaScript Document
var IE4 = (document.all) ? true : false;
var NS4 = (document.layers) ? true : false;
function openDialog(url,theName, width, height, bResize,tbar, bLoc, mbar, stat, bScroll) {
	// Initialize properties of the modal dialog object.
	if (!theName){theName='dlog'}
	if (!width){width=640}
	if (!height){height=480}
	if (!bResize){bResize="yes"}
	if (!tbar){tbar="no"}
	if (!bLoc){bLoc="no"}
	if (!mbar){mbar="no"}
	if (!stat){stat="no"}
	if (!bScroll){bScroll="yes"}
	if (NS4) {
		// Center on the main window.
		theleft = window.screenX + ((window.outerWidth - width) / 2)
		thetop = window.screenY + ((window.outerHeight - height) / 2)
		var attr = "screenX=" + theleft + ",screenY=" + thetop + ",scrollbars=" + bScroll + ",status=" + stat + ", menubar=" + mbar + ", toolbar=" + tbar + ", location=" + bLoc  + ", resizable=" + bResize + ",width=" + width + ",height=" + height
	} 
	else {
		// The best we can do is center in screen.
		theleft = (screen.width - width) / 2
		thetop = (screen.height - height) / 2
		var attr = "left=" + theleft + ",top=" + thetop + ",scrollbars=" + bScroll + ",status=" + stat + ", menubar=" + mbar + ", toolbar=" + tbar + ", location=" + bLoc + ", resizable=" + bResize + ",width=" + width + ",height=" + height
	}
	// Generate the dialog and make sure it has focus.
	thewin=window.open(url,theName, attr)
	thewin.focus()
}