<!--

/////////////////////////
// PRELOAD VON BILDERN //
/////////////////////////

var imagedir="img/";
var myimages=new Array();
function preloadimages(){
	for (i=0;i<preloadimages.arguments.length;i++){
	myimages[i]=new Image()
	myimages[i].src=imagedir + preloadimages.arguments[i]
	}
}
preloadimages(
"m_homepage_on_de.gif",
"m_collection_on_de.gif",
"m_geschichte_on_de.gif",
"m_technik_on_de.gif",
"m_bezug_on_de.gif",
"m_kontakt_on_de.gif",
"m_impressum_on_de.gif",
"m_presse_on_de.gif",
"m_collection_on_tempelhof_over.gif",
"m_collection_on_alex_over.gif",
"m_collection_on_bremen_over.gif",
"m_collection_on_heinkel_over.gif",
"m_collection_on_taifun_over.gif",
"m_collection_on_pocket-golf_over.gif",
"m_collection_on_elly_over.gif",
"m_presse_pressemeldungen_on.gif",
"m_presse_bildarchiv_on.gif",
"m_presse_presseverteiler_on.gif",
"m_presse_pressekontakt_on.gif"
);

/////////////////
// SUBMIT FORM //
/////////////////

function SubmitForm(form){
//document.form.submit();

for (i=0; i<document.form.length; i++) {
document.form[i].submit();
}

}



/////////////////////
// TOGGLE FUNKTION //
/////////////////////

function toggle(DivID) {
	if (document.layers) { // NN4+
		if (document.layers[DivID].visibility == 'visible') {
		document.layers[DivID].visibility = "hide";
		document.layers[DivID].display = "none";
		}else{
		document.layers[DivID].visibility = "show";
		document.layers[DivID].display = "inline";
		}
	} else if(document.getElementById) { // gecko(NN6) + IE 5+
	var obj = document.getElementById(DivID);
		if (obj.style.visibility == 'visible') {
		obj.style.visibility = "hidden";
		obj.style.display = "none";
		}else{
		obj.style.visibility = "visible";
		obj.style.display = "inline";
		}
	} else if (document.all) { // IE 4
		if (document.all[DivID].style.visibility == 'visible') {
		document.all[DivID].style.visibility = "hidden";
		document.all[DivID].style.display = "none";
		}else{
		document.all[DivID].style.visibility = "visible";
		document.all[DivID].style.display = "inline";
		}
	}
}




/////////////////////////////
// ZU FAVORITEN HINZUFÜGEN //
/////////////////////////////

function bookmark(){
if (window.external){
window.external.AddFavorite(document.location,document.title); 
}else{ 
alert("Ihr Browser hat dieses Feature nicht.");
}
}

//////////////////////////
// EINFACHER HTML POPUP //
//////////////////////////

function popHTML(url,pwidth,pheight) {
var left = (screen.width/2)-(pwidth/2);
var top = (screen.height/2)-(pheight/2);
NewWin=window.open('' + url + '','NewWin','width=' + pwidth + ',height=' + pheight + ',resizable=1,top=' + top + ',left=' + left + '');
}

//////////////////////////
// EINFACHER BILD POPUP //
//////////////////////////

var newwindow;
var wheight = 0, wwidth = 0;
function popup(url, title, iwidth, iheight, colour) {
var pwidth, pheight;
// SCREEN MITTE
links = (screen.width/2)-(iwidth/2);
oben = (screen.height/2)-(iheight/2);
if ( !newwindow || newwindow.closed ) {
pwidth=iwidth+30;
pheight=iheight+30;
newwindow=window.open('','htmlname','width=' + pwidth +',height=' +pheight + ',resizable=1,top='+oben+',left='+links);
wheight=iheight;
wwidth=iwidth;
}
if (wheight!=iheight || wwidth!=iwidth ) {
pwidth=iwidth+30;
pheight=iheight+60;
newwindow.resizeTo(pwidth, pheight);
wheight=iheight;
wwidth=iwidth;
}
newwindow.document.clear();
newwindow.focus();
newwindow.document.writeln('<html>');
newwindow.document.writeln('<head>');
newwindow.document.writeln('<title>' + title + '<\/title>');
newwindow.document.writeln('<\/head>');
newwindow.document.writeln('<body bgcolor= \"' + colour + '\">');
newwindow.document.writeln('<table border=\"0\" width=\"100%\" height=\"100%\" cellspacing=\"0\" cellpadding=\"0\"><tr><td width=\"100%\" align=\"center\">');
newwindow.document.writeln('<a href=\"javascript:window.close()\">');
newwindow.document.writeln('<img src=' + url + ' border=\"0\" alt=\"Fenster schließen\">');
newwindow.document.writeln('<\/a>');
newwindow.document.writeln('<\/td><\/tr><\/table>');
newwindow.document.writeln('<\/body>');
newwindow.document.writeln('<\/html>');
newwindow.document.close();
newwindow.focus();
}
function tidy5() {
if (newwindow && !newwindow.closed) { newwindow.close(); }
}

//-->