function DoBild(BILD) {
	var x = 5;
	var y = y1 = 450;
	var Bw = Bw1 = 935;
	try
	{
		if (document.all) y = document.body.scrollTop + 20;
		else y = window.pageYOffset + 20;
		if (y < y1) y = y1;
		
		if (document.all) Bw = document.body.offsetWidth
		else if (document.getElementById) Bw = document.body.clientWidth;
		if (Bw < Bw1) Bw = Bw1;
		x = (Bw-Bw1)/2 + 180;
	}
	catch(e) {}

info1 = "<table border=0 cellspacing=0 cellpadding=3><tr><td bgcolor=#FFFFFF><a href=\"javascript:MM_showHideLayers('Layer1','','hide')\"><img src='" + BILD + "' alt='Bitte klicken zum Verkleinern' border=0></a></td></tr></table>";
	MM_showHideLayers('Layer1','','show');
	if(document.layers) {
		document.Layer1.left = x;
		document.Layer1.top = y;
		document.Layer1.document.write(info1);
		document.Layer1.document.close();
	} else {
		if (document.all) KL = Layer1;
		else KL = document.getElementById("Layer1");
		
		KL.style.left = x;
		KL.style.top = y;
		KL.innerHTML = info1;
	}
}

function MM_findObj(n, d) { //v4.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i>d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && document.getElementById) x=document.getElementById(n); return x;
}

function MM_showHideLayers() { //v3.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v='hide')?'hidden':v; }
    obj.visibility=v; }
}

function OpenFoto(BildURL, x, y) {
var win = "";
win = window.open("","bild",'height=' + y + ',width=' + x +',location=0,status=0,toolbar=no,resizable=0,scrollbar=no,top=0,left=0');
win.document.writeln('<html><head><title>Das Bild</title>');
win.document.writeln('<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">');
win.document.writeln('</head><body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">');
win.document.writeln('<table width="100%" border="0" cellspacing="0" cellpadding="0" height="100%">');
win.document.writeln('<tr><td align="center">');
win.document.writeln('<a href="javascript:window.close()">');
win.document.writeln('<img src="' + BildURL + '" border=0  alt="Fenster schließen">');
win.document.writeln('</a></td></tr></table></body></html>');
win.document.close();
//win.resizeTo(x,y);
win.focus();
}

//if (top.window.frames.length < 2 && top.window.name != "printversion") top.location.href="http://www.bankhaus-mustermann.de/frameset.php?pref=" + escape(window.location.pathname);

function BildDown(DownURL,winfeatures) {
	window.open(DownURL,'Filedown','top=0,left=0' + (winfeatures ? (','+winfeatures) : '') );
}

/***   Editable: ***/
var backcolor	= '#336699';		// Hintergrund
var bordercolor	= '#CCCCCC';		// Ramenfarbe
var textcolor	= '#FFFFFF';		// Textfarbe
var displaytime	= '1000000';		// Zeit
var tablewidth	= '230';			// Tabellenbreite in px
var object		= 'Layer1';			// objekt - Ebene ID
/*******************/
var tipTimer;	// dHTML Toolltip Timer

function locateObject(n, d) { //v3.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i>d.layers.length;i++) x=locateObject(n,d.layers[i].document); return x;
}

function hideKommentar() 
{	if (document.all) {
		locateObject(object).style.visibility="hidden";
		locateObject(object).style.left = 1;
		locateObject(object).style.top = 1;
		return false
	} else if (document.layers) {
		locateObject(object).visibility="hide";
		locateObject(object).left = 1;
		locateObject(object).top = 1;
		return false
	} else if (document.getElementById&&!document.all) {
		document.getElementById(object).style.visibility="hidden";
		document.getElementById(object).style.left = 1;
		document.getElementById(object).style.top = 1;
		return false;
	} else return true;
}

function showKommentar(e, tipContent)
{	window.clearTimeout(tipTimer);
	if (document.all)
	{		locateObject(object).style.top=document.body.scrollTop+event.clientY-10;
			locateObject(object).innerHTML='<table style="font-family: Arial, Helvetica, sans-serif; font-size: 11px; border: '+bordercolor+'; border-style: solid; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; background-color: '+backcolor+'" width="'+tablewidth+'" border="0" cellspacing="1" cellpadding="1"><tr><td><font style="font-family: Tahoma, Arial, Helvetica, sans-serif; font-size: 11px; color: '+textcolor+'">'+unescape(tipContent)+'</font></td></tr></table>';
			if ((e.x + locateObject(object).clientWidth) > (document.body.clientWidth + document.body.scrollLeft))
			{	locateObject(object).style.left = (document.body.clientWidth + document.body.scrollLeft) - locateObject(object).clientWidth-50;
			} else locateObject(object).style.left=document.body.scrollLeft+event.clientX+30;
		locateObject(object).style.visibility="visible";
		tipTimer=window.setTimeout("hideKommentar('"+object+"')", displaytime);
		return true;
	} else if (document.layers)
	{	locateObject(object).document.write('<table width="'+tablewidth+'" border="0" cellspacing="1" cellpadding="1"><tr bgcolor="'+bordercolor+'"><td><table width="100%" border="0" cellspacing="0" cellpadding="2"><tr bgcolor="'+backcolor+'"><td><font style="font-family: Tahoma, Arial, Helvetica, sans-serif; font-size: 11px; color: '+textcolor+'">'+unescape(tipContent)+'</font></td></tr></table></td></tr></table>')
		locateObject(object).document.close();
		locateObject(object).top=e.y-10;
		if ((e.x + locateObject(object).clip.width) > (window.pageXOffset + window.innerWidth)) locateObject(object).left = window.innerWidth - locateObject(object).clip.width-80;
		else locateObject(object).left=e.x+30;
		locateObject(object).visibility="show";
		tipTimer=window.setTimeout("hideKommentar('"+object+"')", displaytime);
		return true;
	} else if (document.getElementById&&!document.all)
	{	document.getElementById(object).style.top= window.pageYOffset + e.clientY-10;		
		document.getElementById(object).innerHTML='<table style="font-family: Arial, Helvetica, sans-serif; font-size: 11px; border: '+bordercolor+'; border-style: solid; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; background-color: '+backcolor+'" width="'+tablewidth+'" border="0" cellspacing="1" cellpadding="1"><tr><td><font style="font-family: Tahoma, Arial, Helvetica, sans-serif; font-size: 11px; color: '+textcolor+'">'+unescape(tipContent)+'</font></td></tr></table> ';
		if ((e.clientX + window.innerWidth - tablewidth - 80) > (window.pageXOffset + window.innerWidth)) document.getElementById(object).style.left = window.pageXOffset + e.clientX-tablewidth-50;
		else document.getElementById(object).style.left=window.pageXOffset + e.clientX+30;
		document.getElementById(object).style.visibility="visible";
		tipTimer=window.setTimeout("hideKommentar('"+object+"')", displaytime);
		return true;
	} else return true;
}
function Webmerk() {
	if (document.all) // IE
	{
		if (confirm('Möchten Sie die Webseite - Hotel Zur Post zu Ihren Favoriten hinzufügen?')) window.external.addFavorite('http://www.hotelzurpost-welling.de','Hotel Restaurant Zur Post');
	}
	else if (document.layers) // NS 4
	{
		alert("PC-Systeme:\nDrücken Sie Strg + D\n\nApple-Macintosh-Systeme:\nDrücken Sie Befehlstaste + D");
	} else if (!document.all && document.getElementById) {
		if(navigator.appName == "Netscape") { // NS > 6
			alert("PC-Systeme:\nDrücken Sie Strg + D\n\nApple-Macintosh-Systeme:\nDrücken Sie Befehlstaste + D");
		}
	}
}

//*******************************************

var ISZero = 0;

function MakeFontSize(PLUSSize) {
	FontnameArr = new Array("xx-small", "x-small", "small", "medium", "large", "x-large", "xx-large");
	if ( (ISZero <= -3 && PLUSSize > 0) || (ISZero >= 7 && PLUSSize < 0) || (ISZero < 7 && ISZero > -3) ) {
		ISZero += PLUSSize;
		for(i=0; i < document.styleSheets[0].rules.length; i++)
		{
			if (document.styleSheets[0].rules[i].style.fontSize != null) {
				FontString = new String(document.styleSheets[0].rules[i].style.fontSize);
				ISFONTNONAME = -1;
				for (j = 0; j < FontnameArr.length; j++) {
					if (FontString == FontnameArr[j]) {
						ISFONTNONAME = j;
						break;
					}
				}
				
				if (ISFONTNONAME == -1) {
					ClassFontSize = (FontString.substr(0, FontString.length-2)) * 1;
					ClassFontFormat = FontString.substr(FontString.length-2, 2);
					if (ClassFontSize > 1 ) {
						ClassFontSize += PLUSSize;
						document.styleSheets[0].rules[i].style.fontSize = (ClassFontSize +  ClassFontFormat);
					}
				} else {
					ISFONTNONAME += PLUSSize
					if (ISFONTNONAME > -1 && ISFONTNONAME < FontnameArr.length)
						document.styleSheets[0].rules[i].style.fontSize = FontnameArr[ISFONTNONAME];
				}
			}
		}
	}
}

function LinksUpdate()
{
	if (document.getElementById)
	{
		if (ALinkE1 != "")
		{
			document.getElementById("link_" + ALinkE1).className = "e1_act";
			document.getElementById("BarTop").className = "color1";
		}
		else
		{
			document.getElementById("BarBottom").className = "color1";
		}
		if (ALinkE2 != "")
		{
			document.getElementById("link_" + ALinkE2).className = "e2_act";
		}
		if (ALinkE3 != "")
		{
			document.getElementById("link_" + ALinkE3).className = "e3_act";
		}
		if (ALinkE4 != "")
		{
			document.getElementById("link_" + ALinkE4).className = "e4_act";
		}
	}
}

