function openPop(filename, width, height) {
	
	x = (640 - width)/2, y = (480 - height)/2;

   	if (screen) {
      	 	y = (screen.availHeight - height)/2;
       	x = (screen.availWidth - width)/2;
   	}


	var page = filename;
	var windowprops = "height=" + height + ",width=" + width + ",location=no,status=no,scrollbars=yes,menubar=no,toolbar=no,resizable=yes,left="+x+",top="+y;
	var popup = window.open(page, "popUp", windowprops);
}

function openPrint(filename, width, height) {

	x = (640 - width)/2, y = (480 - height)/2;

   	if (screen) {
      	 	y = (screen.availHeight - height)/2;
       	x = (screen.availWidth - width)/2;
   	}


	var page = filename;
	var windowprops = "height=" + height + ",width=" + width + ",location=no,status=no,scrollbars=yes,menubar=yes,toolbar=no,resizable=yes,left="+x+",top="+y;
	var popup = window.open(page, "print", windowprops);
}

function openChat(filename, width, height) {

	x = (640 - width)/2, y = (480 - height)/2;

   	if (screen) {
      	 	y = (screen.availHeight - height)/2;
       	x = (screen.availWidth - width)/2;
   	}


	var page = filename;
	var windowprops = "height=" + height + ",width=" + width + ",location=no,status=no,scrollbars=no,menubar=no,toolbar=no,resizable=no,left="+x+",top="+y;
	var popup = window.open(page, "chat", windowprops);
}

function openExport(filename, width, height) {

	x = (640 - width)/2, y = (480 - height)/2;

   	if (screen) {
      	 y = (screen.availHeight - height)/2;
       	x = (screen.availWidth - width)/2;
   	}


	var page = filename;
	var windowprops = "height=" + height + ",width=" + width + ",location=no,status=no,scrollbars=yes,menubar=yes,toolbar=no,resizable=yes,left="+x+",top="+y;
	var popup = window.open(page, "popUp", windowprops);
}
