// author Michael Suesz <michael@suesz.de>
// http://www.validome.org/doc/HTML_ge/javascript/objekte/window.htm#open

function jsscreenkiosk(url, name_without_space, w, h, left, top ) {
	if(left==""){left=(screen.width)?(screen.width-w)/2:100;}   // center
	if(top=="") {top=(screen.height)?(screen.height-h)/2:100;}  // center	

	//w="800";   //debug
	//h="600";  //debug
	options1 = "width="+w+",height="+h+",top="+top+",left="+left+",";
	options2 = "dependent=yes,location=no,menubar=no,resizable=no,scrollbars=no,status=no,toolbar=no"; 
	
	w=window.open(url, name_without_space, options1+options2);
	w.window.moveTo(left,top);	//(left,top);
	w.window.focus();
} 

function jsscreen(url, name_without_space, w, h, left, top ) {
	if(left==""){left=(screen.width)?(screen.width-w)/2:100;}  	// center
	if(top=="") {top=(screen.height)?(screen.height-h)/2:100;}	// center

	//w="800";   //debug
	//h="600";  //debug
	options1 = "width="+w+",height="+h+",top="+top+",left="+left+",";
	options2 = "dependent=yes,location=no,menubar=no,resizable=yes,scrollbars=no,status=no,toolbar=no,    directories=no,status=yes,";
	
	w=window.open(url, name_without_space, options1+options2);
	w.window.moveTo(left,top);	//(left,top);
	w.window.focus();
} 


function jsscreenpdf(url, name_without_space, w, h, left, top ) {
	if(left==""){left=(screen.width)?(screen.width-w)/2:100;}   // center
	if(top=="") {top=(screen.height)?(screen.height-h)/2:100;}  // center	

	//w="800";   //debug
	//h="600";  //debug
	options1 = "width="+w+",height="+h+",top="+top+",left="+left+",";
	options2 = "dependent=yes,location=no,menubar=no,resizable=yes,scrollbars=yes,status=yes,toolbar=yes";

	w=window.open(url, name_without_space, options1+options2);
	w.window.moveTo(left,top);	//(left,top);
	w.window.focus();
} 


function jsscreenadmin(url, name_without_space, w, h, left, top ) {
	if(left==""){left=(screen.width)?(screen.width-w)/2:100;}   // center
	if(top=="") {top=(screen.height)?(screen.height-h)/2:100;}  // center	

	//w="800";   //debug
	//h="600";  //debug
	options1 = "width="+w+",height="+h+",top="+top+",left="+left+",";
	options2 = "dependent=yes,location=no,menubar=no,resizable=yes,scrollbars=yes,status=yes,toolbar=yes"; 
	
	w=window.open(url, name_without_space, options1+options2);
	w.window.moveTo(left,top);	//(left,top);
	w.window.focus();
} 


function jsscreendefault(url, name_without_space, w, h, left, top ) {
	if(left==""){left=(screen.width)?(screen.width-w)/2:100;}   // center
	if(top=="") {top=(screen.height)?(screen.height-h)/2:100;}  // center	

	//w="800";   //debug
	//h="600";  //debug
	options1 = "width="+w+",height="+h+",top="+top+",left="+left+",";
	options2 = "dependent=yes,location=no,menubar=yes,resizable=yes,scrollbars=yes,status=yes,toolbar=yes"; 
	
	w=window.open(url, name_without_space, options1+options2);
	w.window.moveTo(left,top);	//(left,top);
	w.window.focus();
} 
