function OpenNewWindow(Seite,Breit,Hoch) {
	xsize = Breit;
	ysize = Hoch;

	ScreenWidth = screen.width;
	ScreenHeight = screen.height;

	xpos = (ScreenWidth/2)-(xsize/2);
	ypos = (ScreenHeight/2)-(ysize/2);

        NewWindow=window.open(Seite,"","height="+ysize+",width="+xsize+", scrollbars=yes,status=no,menubar=no,toolbar=no,resizable=no, top="+ypos+",left="+xpos+"");     
}

function OpenNewPicture(image,breit,hoch) {
	xsize = breit;
	ysize = hoch;

	ScreenWidth = screen.width;
	ScreenHeight = screen.height;

	xpos = (ScreenWidth/2)-(xsize/2);
	ypos = (ScreenHeight/2)-(ysize/2);

        NewWindow=window.open("","image","height="+ysize+",width="+xsize+", scrollbars=no,status=no,menubar=no,toolbar=no,resizable=no, top="+ypos+",left="+xpos+"");

	NewWindow.document.write ("<html><head><title> Fachschaft CUB - Bild</title><link rel='stylesheet' type='text/css' href='../style.css'>");
	NewWindow.document.write ("</head>");
	NewWindow.document.write ("<body bgcolor=#ffffff leftmargin=0 topmargin=0 marginheight=0>");
	NewWindow.document.write ("<table width='100%' height='100%' cellpadding='0' cellspacing='0' border='0'>");
	NewWindow.document.write ("<tr><td width='32px' height='100%' style=\"background-image:url('../images/block_background.jpg')\"></td>");
	NewWindow.document.write ("<td style=\"background-image:url('../images/spacer.jpg')\">");
	NewWindow.document.write ("<table width='100%' cellpadding='15'>");
	NewWindow.document.write ("<tr><td align='center'><img style='border-width:1px; border-color:#000000; border-style:solid; padding:1px;' src=");
	NewWindow.document.write (image);
	NewWindow.document.write ("></td></tr><tr><td>");
	NewWindow.document.write ("<center><div class='Stil_klein'><b>Zum Speichern</b> : Rechte Maustaste -> Bild speichern unter</div><br><a href='javascript:self.close()'>Schliessen</a></center>");
	NewWindow.document.write ("</td></tr></table></td>");
	NewWindow.document.write ("<td width='32px' height='100%' style=\"background-image:url('../images/block_background.jpg')\"></td>");
	NewWindow.document.write ("</tr></table></body></html>");
}

function newImage(arg) {
	if (document.images) {
		rslt = new Image();
		rslt.src = arg;
		return rslt;
	}
}

function changeImages() {
	if (document.images && (preloadFlag == true)) {
		for (var i=0; i<changeImages.arguments.length; i+=2) {
			document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
		}
	}
}
