/*	lg standard JavaScript Collection v2.01
 *  last edited 01.04.2007 19:26:12
 */

/*	displays statusbar message v1.01
 *	param: message - string
 */
function dsplSM( message ) {
	window.status = message;
}

/* switches class v1.02
 * param: cell - string
 * param: clas - string
 */
function hov( cell, clas) {
	cell.className = clas;
}

/* opens popup windows v1.02
 * param: url - string
 * param: width - int
 * param: height - int
 * param: mode - int (1 = regular, 2 = fullscreen)
 */
function popup( url, width, height, mode ) {
	if (width == null) { width = 700; }
	if (height == null) { height = 600; }
	if (mode == null) { mode = 1; }
	if (mode == 1) {
		splashWin = window.open(url, Math.ceil(Math.random()), 'scrollbars=auto, resizable=yes, width='+width+', height='+height);
	} else {
		splashWin = window.open(url, Math.ceil(Math.random()), 'fullscreen=1, toolbar=0, location=0, directories=0, status=0, menubar=0, scrollbars=no, resizable=0' );
        splashWin.resizeTo(width, height);
	}
	if (parseInt(navigator.appVersion) >= 4) {
		splashWin.moveTo((screen.width/2)-(width/2),(screen.height/2)-(height/2));
	}
	splashWin.focus();
}

/* prints botsafe email v1.01
 * param: name - string
 * param: tld - string
 * param: alt - string
 */
function prntMl(name, tld, alt) {
	if (name == null) { name = 'email'; }
	if (tld == null) { tld = 'dsp-d.com'; }
	if (alt == null) { alt = name + "&#64\;" + tld; }
	document.write("<a href=\"mailto:" + name);
	document.write("&#64\;" + tld + "\">");
	document.write(alt + "</a>");
}

/* shows and hides layers v1.02
 * param: divID - string
 */
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+
    for (var i = 0; i < document.getElementsByTagName("div").length; i++) {
      oID = document.getElementsByTagName("div")[i].id;
      if (oID != divID) {
        var obj = document.getElementById(oID);
        var objS = document.getElementById(divID+"S");
        if (obj.style.visibility == 'visible') {
          obj.style.visibility = "hidden";
          obj.style.display = "none";
        }
      } else {
        var obj = document.getElementById(divID);
        var objS = document.getElementById(divID+"S");
        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";
    }
  }
}
/*eingefügt
*/
var loading_time=0;
var loading_page=true;
window.status = "Loading ";
function updateStatus() {
 if (loading_page) {
  loading_time++;
  window.status += ".";
  timerID=setTimeout("updateStatus()",200);
 } else {
  window.status="Die Seite wurde in "+(loading_time/50)+" Sekunden geladen.";
 }
}
updateStatus();
function dsplSM(msg) {
 window.status=msg;
 document.returnValue = true;
}
function popup (url,width,height) {
 window.open(url,'Window','scrollbars=yes,resizable=yes,width='+width+',height='+height);
}
function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}
function MM_displayStatusMsg(msgStr) { //v1.0
  status=msgStr;
  document.MM_returnValue = true;
}
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
function MM_findObj(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=MM_findObj(n,d.layers[i].document); return x;
}
function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
