function openpopup (myfile, myname, breite, hoehe) {
	params = "width=" + breite + ",height=" + hoehe + ",resizable=0,status=0,scrollbars=0,toolbar=0,location=0,directories=0,menubar=1";
	newwin = window.open( myfile , myname , params)
	if (window.focus){newwin.focus()} // popup nach vorne bringen, wenn es hinten ist
}

function openpopupscroll (myfile, myname, breite, hoehe) {
	params = "width=" + breite + ",height=" + hoehe + ",resizable=1,status=0,scrollbars=1,toolbar=0,location=0,directories=0,menubar=1";
	newwin = window.open( myfile , myname , params)
	if (window.focus){newwin.focus()} // popup nach vorne bringen, wenn es hinten ist
}

function openpopupdyn (myfile, mytext, myname, breite, hoehe) {
	params = "width=" + breite + ",height=" + hoehe + ",resizable=0,status=0,scrollbars=1,toolbar=0,location=0,directories=0,menubar=0";
	//alert(myfile.substring(61));
	newwin = window.open( myfile , myname , params);
	newwin.focus(); // popup nach vorne bringen, wenn es hinten ist
	newwin.document.open(); // popup nach vorne bringen, wenn es hinten ist
	with(newwin)
	{
		document.write("<html><head>");
		document.write("<title>Klimadiagramm</title>");
		document.write ("<link rel='stylesheet' type='text/css' href='/tis/vorlagen/include/css/styles.css' media='screen'>");
		document.write ("<link rel='stylesheet' type='text/css' href='/tis/vorlagen/include/css/print_styles.css' media='print'>");
		document.write ("<script language='javascript' src='/tis/vorlagen/include/js/openpop.js'></script>");
		document.write("</head>");
		document.write("<body leftmargin='0' marginheight='0' marginwidth='0' topmargin='0'>");
        document.write("<div align='center'><img border='0' src='"+ myfile +"' title=''></div><br><br>");
        if(mytext!=0){
			document.write("<div class='h1' align='center'>"+ mytext +"</div><br><br><br>");
		}
		document.write("<div align='center'><a href='javascript:window.close();'>[Fenster schlie&szlig;en]</a></div><br>");
		document.write("<img src='/tis/vorlagen/images/pfad_linie_verlauf.gif' width='100%' height='1' alt='' border='0'><br>");
		document.write("&copy; Gesamtverband der Deutschen Versicherungswirtschaft e. V. (GDV), <br>Berlin 1999-2010, ");
		document.write("<a href='http://www.tis-gdv.de' target='_blank'>www.tis-gdv.de</a>");
        document.write("</body></html>");
	}
	newwin.document.close();
}

function openpopupdynswf (myfile, myname, breite, hoehe, bildbreite, bildhoehe) {
	params = "width=" + breite + ",height=" + hoehe + ",resizable=0,status=0,scrollbars=1,toolbar=0,location=0,directories=0,menubar=0";
	newwin = window.open( myfile , myname , params);
	newwin.focus(); // popup nach vorne bringen, wenn es hinten ist
	newwin.document.open(); // popup nach vorne bringen, wenn es hinten ist
	//alert(myfile);
	with(newwin)
	{
		document.write("<html><head>");
		document.write("<title>Klimastationen</title>");
		document.write ("<link rel='stylesheet' type='text/css' href='/tis/vorlagen/include/css/styles.css' media='screen'>");
		document.write ("<link rel='stylesheet' type='text/css' href='/tis/vorlagen/include/css/print_styles.css' media='print'>");
		document.write ("<script language='javascript' src='/tis/vorlagen/include/js/openpop.js'></script>");
		document.write("</head>");
		document.write("<body bgcolor='#ffffff'><br>");
        document.write("<div align='center'><object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0' width='"+ bildbreite +"' height='" + bildhoehe +"' id='" + myfile + "' align='middle'>");
        document.write("<param name='allowScriptAccess' value='sameDomain' />");
        document.write("<param name='movie' value='" + myfile + "' />");	
        document.write("<param name='quality' value='high' />");
        document.write("<param name='wmode' value='transparent' />");
        document.write("<param name='bgcolor' value='#ffffff' />");
        document.write("<embed src='" + myfile + "' quality='high' wmode='transparent' bgcolor='#ffffff' width='" + bildbreite +"' height='" + bildhoehe +"' name='" + myfile + "' align='middle' allowScriptAccess='sameDomain' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' />");
        document.write("</object></div><br><br><br>");
		document.write("<div align='center'><a href='javascript:window.close();'>[Fenster schlie&szlig;en]</a></div><br>");
		document.write("<img src='/tis/vorlagen/images/pfad_linie_verlauf.gif' width='100%' height='1' alt='' border='0'><br>");
		document.write("&copy; Gesamtverband der Deutschen Versicherungswirtschaft e. V. (GDV), <br>Berlin 1999-2010, ");
		document.write("<a href='http://www.tis-gdv.de' target='_blank'>www.tis-gdv.de</a>");
        document.write("</body></html>");
	}
	newwin.document.close();
}

//Versteckten Text aufklappen
function toggledisplay (id, indicator){ 
	if (document.getElementById) { 
		var obj = document.getElementById(id);
		var pic = document.getElementsByName(indicator);
		obj.style.display = (obj.style.display=='block'?'none':'block');
		switch (id) {
		case 'hiddenDiv1':
		pic[0].src = (obj.style.display=='block'?/*VIPURL*/'/tis/vorlagen/images/hide.gif':/*VIPURL*/'/tis/vorlagen/images/show.gif');
		break;
		case 'hiddenDiv2':
		pic[1].src = (obj.style.display=='block'?/*VIPURL*/'/tis/vorlagen/images/hide.gif':/*VIPURL*/'/tis/vorlagen/images/show.gif');
		break;
		case 'hiddenDiv3':
		pic[2].src = (obj.style.display=='block'?/*VIPURL*/'/tis/vorlagen/images/hide.gif':/*VIPURL*/'/tis/vorlagen/images/show.gif');
		break;
		case 'hiddenDiv4':
		pic[3].src = (obj.style.display=='block'?/*VIPURL*/'/tis/vorlagen/images/hide.gif':/*VIPURL*/'/tis/vorlagen/images/show.gif');
		break;
		}
	} else if(document.all) { // IE
		id.style.display = (id.style.display=='block'?'none':'block');
		indicator.src = (id.style.display=='block'?/*VIPURL*/'/tis/vorlagen/images/hide.gif':/*VIPURL*/'/tis/vorlagen/images/show.gif');
	} else if (document.layers) { // Netscape 4.x
		document.id.style.display = (document.id.style.display=='block'?'none':'block');
		document.indicator.src = (document.id.style.display=='block'?/*VIPURL*/'/tis/vorlagen/images/hide.gif':/*VIPURL*/'/tis/vorlagen/images/show.gif');
	}
}

//funktionen zum versenden eines formulars
function formularSendenHK(zieldatei) {
	document.hkom.method='get';
	document.hkom.action=zieldatei;
	document.hkom.submit();
	document.hkom.reset();
}

function formularSendenLH(zieldatei) {
	document.landinfo.method='get';
	document.landinfo.action=zieldatei;
	document.landinfo.submit();
}

//funktionen für das hk_verzeichnis
/*function ChangeBland(bland){
	document.hkom.method='get';
	document.hkom.action='weiterleiten.php';
	document.hkom.submit();
	document.hkom.reset();

}*/
function ChangeBland(bland){
	switch(bland) {
	 case "1":
		formularSendenHK('bawu.php');
/*		document.hkom.method="post";
		document.hkom.action="bawu.php";
		document.hkom.submit();
*/
	 break;
	 case "2":
		formularSendenHK('baye.php');
	 break;
	 case "3":
		formularSendenHK('berl.php');
	 break;
	 case "4":
		formularSendenHK('brbu.php');
	 break;
	 case "5":
		formularSendenHK('brem.php');
	 break;
	 case "6":
		formularSendenHK('hamb.php');
	 break;
	 case "7":
		formularSendenHK('hess.php');
	 break;
	 case "8":
		formularSendenHK('mevo.php');
	 break;
	 case "9":
		formularSendenHK('nisa.php');
	 break;
	 case "10":
		formularSendenHK('nowe.php');
	 break;
	 case "11":
		formularSendenHK('rhpf.php');
	 break;
	 case "12":
		formularSendenHK('sala.php');
	 break;
	 case "13":
		formularSendenHK('sach.php');
	 break;
	 case "14":
		formularSendenHK('saan.php');
	 break;
	 case "15":
		formularSendenHK('scho.php');
	 break;
	 case "16":
		formularSendenHK('thue.php');
	 break;
	 default:
		formularSendenHK('ort.php');
	 break;
	}
} 

function ChangeOrt(blandnr) {
	document.hkom.method='get';
	document.hkom.action='ort.php';
	document.hkom.submit();
	document.hkom.reset();

}
/*function ChangeOrt(blandnr){
	switch(blandnr) {
	 case "1":
		formularSendenHK('weiterleiten.php');*/
/*		document.hkom.method="post";
		document.hkom.action="bawu_ergebnis.php";
		document.hkom.submit();*/
/*	 break;
	 case "2":
		formularSendenHK('baye_ergebnis.php');
	 break;
	 case "3":
		formularSendenHK('berl_ergebnis.php');
	 break;
	 case "4":
		formularSendenHK('brbu_ergebnis.php');
	 break;
	 case "5":
		formularSendenHK('brem_ergebnis.php');
	 break;
	 case "6":
		formularSendenHK('hamb_ergebnis.php');
	 break;
	 case "7":
		formularSendenHK('hess_ergebnis.php');
	 break;
	 case "8":
		formularSendenHK('mevo_ergebnis.php');
	 break;
	 case "9":
		formularSendenHK('nisa_ergebnis.php');
	 break;
	 case "10":
		formularSendenHK('nowe_ergebnis.php');
	 break;
	 case "11":
		formularSendenHK('rhpf_ergebnis.php');
	 break;
	 case "12":
		formularSendenHK('sala_ergebnis.php');
	 break;
	 case "13":
		formularSendenHK('sach_ergebnis.php');
	 break;
	 case "14":
		formularSendenHK('saan_ergebnis.php');
	 break;
	 case "15":
		formularSendenHK('scho_ergebnis.php');
	 break;
	 case "16":
		formularSendenHK('thue_ergebnis.php');
	 break;*/
	 /*default:
		document.hkom.method="post";
		document.hkom.action="ort.php";
		document.hkom.submit();
	 break;*/
/*	}
}*/

//funktion für die länderinfos
function selectKontinent(kontinent){
	switch(kontinent) {
	 case "1":
		formularSendenLH('afri.php');
	 break;
	 case "2":
		formularSendenLH('asia.php');
	 break;
	 case "3":
		formularSendenLH('aust.php');
	 break;
	 case "4":
		formularSendenLH('euro.php');
	 break;
	 case "5":
		formularSendenLH('miam.php');
	 break;
	 case "6":
		formularSendenLH('noam.php');
	 break;
	 case "7":
		formularSendenLH('suam.php');
	 break;
	}
}

function formReset(){
	if (document.forms['hkom']){
		document.forms['hkom'].reset();
	}
	if (document.forms['landinfo']){
		document.forms['landinfo'].reset();
	}
}

function sendeVariable(){
	if(document.hkom.blandnr){
	
document.getElementById("deutschland_klein").setVariable("bland",document.hkom.blandnr.value)
	//alert(document.hkom.blandnr.value);
	}
}

function selectLand(land){
		document.landinfo.method="get";
		document.landinfo.action="lh_erg.php";
		document.landinfo.submit();
}

//Funktion zum Öffnen eines Extrafensters zum Vergrößern der Grafik mit php
function GrafikAnzeigen(GrafikURL, Breite, Hoehe)
{
	Fensteroptionen="toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0";

	Grafikfenster=window.open("", "", Fensteroptionen + ',width=' + Breite + ',height=' + Hoehe);
	Grafikfenster.focus();
	Grafikfenster.document.open();
	with(Grafikfenster)
	{
		document.write("<html><head>");
		document.write("<title>Schadenverhütungstagung 2007</title>");
		document.write("<link rel=\"stylesheet\" type=\"text/css\" href=\"http://wcms2.ham.gdv.org/wcm/TIS_WWW_edit/TIS_WWW/tis/vorlagen/include/css/styles.css\" media=\"screen\">");
		document.write("<link rel=\"stylesheet\" type=\"text/css\" href=\"http://wcms2.ham.gdv.org/wcm/TIS_WWW_edit/TIS_WWW/tis/vorlagen/include/css/print_styles.css\" media=\"print\">");
		document.write("</head>");
		document.write("<body leftmargin=\"0\" marginheight=\"0\" marginwidth=\"0\" topmargin=\"0\">");
		document.write("<div align=\"center\"><img border=\"0\" src=\""+ GrafikURL +"\" title=\"Schadenverhütungstagung 2007\"><br><br>");
		document.write("<a href=\"javascript:window.close();\">[Fenster schlie&szlig;en]</a></div><br>");
		document.write("<img src=\"http://wcms2.ham.gdv.org/wcm/TIS_WWW_edit/TIS_WWW/tis/vorlagen/images/pfad_linie_verlauf.gif\" width=\"100%\" height=\"1\" alt=\"\" border=\"0\"><br>&copy; Gesamtverband der Deutschen Versicherungswirtschaft e. V. (GDV), <br>");
		document.write("Berlin 1999-2010, <a href=\"http://www.tis-gdv.de\" target=\"_blank\">www.tis-gdv.de</a>");
		document.write("</body></html>");
	}
	Grafikfenster.document.close();
}
