var Bild = new Array();
var BildAnz = 44; 
var Nummer; 
function BildPreLoad() {
    for ( N=0; N<BildAnz; N++ ) {
					Bild[N] = new Image();
					tmp = N + 1;
					var nummer = "" + (( tmp > 9 ) ? '0'+tmp : '00' + tmp ); 
					Bild[N].src = 'fotos/Bild'+nummer+'.jpeg';
    }
}
function ZeigeBild(Nummer) {
      Fenster = window.open( '', 'Bild',"resizable=no, width=800, height=630");
			aktPic = "fotos/Bild" + (( Nummer > 9 ) ? '0'+Nummer : '00' + Nummer ) +".jpg";
          Fenster.innerHeight=630;
          Fenster.innerWidth=800;
    			Fenster.document.writeln( "<html><head>" );
					Fenster.document.writeln( "<script LANGUAGE=\"JavaScript\" type=\"text/javascript\">");
					Fenster.document.writeln( "var BildNum = "+Nummer+";var BildMax = "+BildAnz+";");
					Fenster.document.writeln( "function wechsel( Schritt ) {" );
					Fenster.document.writeln( "NeuNum = BildNum + Schritt;" );
					Fenster.document.writeln( "aktPic = \"fotos/Bild\" + (( NeuNum > 9 ) ? '0'+NeuNum : '00' + NeuNum)+'.jpeg';" );
					Fenster.document.writeln( "eval('document.getElementById(\"foto\").src = \"'+aktPic+'\"') ;" );
					Fenster.document.writeln( "BildNum = NeuNum;" );
					Fenster.document.writeln( "if ( BildNum == 1 ) {" );
					Fenster.document.writeln( "	 document.getElementById(\"back\").style.visibility = \"hidden\";" );
					Fenster.document.writeln( "} else {" );
					Fenster.document.writeln( "	 document.getElementById(\"back\").style.visibility = \"visible\";" );
					Fenster.document.writeln( "}" );
					Fenster.document.writeln( "if ( BildNum == BildMax ) {" );
					Fenster.document.writeln( "	 document.getElementById(\"next\").style.visibility = \"hidden\";" );
					Fenster.document.writeln( "} else {" );
					Fenster.document.writeln( "	 document.getElementById(\"next\").style.visibility = \"visible\";" );
					Fenster.document.writeln( "}" );
					Fenster.document.writeln( "}" );
					Fenster.document.writeln( "<\/script>" );
/*					Fenster.document.writeln( "<SCRIPT LANGUAGE=\"JavaScript\" SRC=\"show.js\" TYPE=\"text/javascript\"><\/SCRIPT>" );*/
    			Fenster.document.writeln( "<title>Bildergalerie<\/title><\/head>" );
    			Fenster.document.writeln( "<body style=\"margin: 0px; padding: 0px; text-align: center;background-color: yellow;\">");
					Fenster.document.writeln( "<img id=\"foto\" alt=\"\" src=\""+aktPic+"\" height=\"600\" width=\"800\">");
					Fenster.document.writeln( "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr>" );
					if ( Nummer > 1 ) {
										Fenster.document.write( "<td id=\"back\" width=\"59\">" );
					} else { 
										Fenster.document.write( "<td id=\"back\" width=\"59\" style=\"visibility: hidden;\">" );
					}
					Fenster.document.writeln( "<a href=\"javascript:wechsel(-1);\"><img alt=\"zurueck\" src=\"zurueck.gif\" height=\"22\" width=\"59\" border=\"0\"><\/a><\/td>" );
    			Fenster.document.writeln( "<td align=\"center\"><a href=\"javascript:this.close()\"><img alt=\"schlie&szlig;en\" src=\"close.gif\" height=\"22\" width=\"59\" border=0><\/a><\/td>" );
					if ( Nummer < BildAnz ) {
										Fenster.document.write( "<td id=\"next\" width=\"59\">" );
					} else { 
										Fenster.document.write( "<td id=\"next\" width=\"59\" style=\"visibility: hidden;\">" );
					}
					Fenster.document.writeln( "<a href=\"javascript:wechsel(1);\"><img alt=\"vor\" src=\"vor.gif\" height=\"22\" width=\"59\" border=\"0\"><\/a><\/td>" );
					Fenster.document.writeln( "<\/tr><\/table>");
					Fenster.document.writeln( "<\/BODY><\/HTML>" );
					Fenster.focus();
}

