
function MM_findObj(n, d) { //v4.01
  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 && d.getElementById) x=d.getElementById(n); return x;
}

function MM_changeProp(objName,x,theProp,theValue) { //v6.0
  var obj = MM_findObj(objName);
  if (obj && (theProp.indexOf("style.")==-1 || obj.style)){
    if (theValue == true || theValue == false)
      eval("obj."+theProp+"="+theValue);
    else eval("obj."+theProp+"='"+theValue+"'");
  }
}

function MM_showHideLayers() { //v6.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 popup(url2go,breite,hoehe)
{
	thepopup = window.open(url2go,'thepopup','width=' + breite + ',height=' + hoehe + ',scrollbars=yes,left=50,top=50');
	thepopup.resizeTo(breite+10,hoehe+29);
	thepopup.focus();
}

function popupimg(imgurl,breite,hoehe)
{
	theimgpopup = window.open('','theimgpopup','width=' + breite + ',height=' + hoehe + ',scrollbars=no,left=50,top=50');
	theimgpopup.document.write('<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><title>[ Beulco Armaturen ]</title><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"><link rel="stylesheet" type="text/css" href="/scripts/style.css"><base href="http://de.beulco.demo.x2-gmbh.de/"></head><body leftmargin="7" topmargin="7" marginwidth="7" marginheight="7"><p><img src="' + imgurl + '" border="1"></p><p><a href="javascript:self.close()">Fenster schlie&szlig;en</a></p></body></html>');
	
	theimgpopup.focus();
}

function popupimg_en(imgurl,breite,hoehe)
{
	theimgpopup = window.open('','theimgpopup','width=' + breite + ',height=' + hoehe + ',scrollbars=no,left=50,top=50');
	theimgpopup.document.write('<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><title>[ Beulco Armaturen ]</title><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"><link rel="stylesheet" type="text/css" href="/scripts/style.css"><base href="http://de.beulco.demo.x2-gmbh.de/"></head><body leftmargin="7" topmargin="7" marginwidth="7" marginheight="7"><p><img src="' + imgurl + '" border="1"></p><p><a href="javascript:self.close()">close window</a></p></body></html>');
	
	theimgpopup.focus();
}

function setActiveStyleSheet(title) {
  var i, a, main;
  for(i=0; (a = document.getElementsByTagName("link")[i]); i++) {
    if(a.getAttribute("rel").indexOf("style") != -1 && a.getAttribute("title")) {
      a.disabled = true;
      if(a.getAttribute("title") == title) a.disabled = false;
    }
  }
}

function setcookie(name,value,days) {
  if (days) {
    var date = new Date();
    date.setTime(date.getTime()+(days*24*60*60*1000));
    var expires = "; expires="+date.toGMTString();
  }
  else expires = "";
  document.cookie = name+"="+value+expires+"; path=/";
}
function form_abschicken_suche() {
  document.search.submit (); 
}
function form_abschicken_sitemap() {
  document.sitemap.submit (); 
}

