// javascript.js
// Autor: Thomas Maldoner | www.maldoner.at
// Zuletzt modifiziert: 01.12.2001


	
	function open_window(target,name,width,height,posx,posy,windowoptions,init_target) {
		var it, wo, px, py

		it = target;
		wo = "location=no,toolbar=no,status=no,statusbar=no,scrollbars=no,resizable=no,dependent=yes";
		
		w = width;
		h = height;
		px = (screen.width - w )/ 2;
		py = (screen.height - h )/ 2;

		if (typeof posx != "undefined") px = posx;
		if (typeof posy != "undefined") py = posy;
		if ((typeof windowoptions != "undefined") && (windowoptions != "")) wo = windowoptions;
		if (typeof init_target != "undefined") it = init_target;

		if(typeof new_window != "undefined") {
			if(new_window.closed != true) {
				new_window.close();
			}
		}
		new_window = window.open(it,name,"width=" + width + ",height=" + height + "," + wo);
		new_window.moveTo(px,py);
		new_window.location.replace(target);
		new_window.focus();
	}


