function merivatec_preloadImages() { // version 3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=merivatec_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 merivatec_swapImageRestore() { // version 3.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 merivatec_swapImage() { // version 3.0
  var i,j=0,x,a=merivatec_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=merivatec_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

function merivatec_findObj(n, d) { // version 4.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=merivatec_findObj(n,d.layers[i].document);
  if(!x && document.getElementById) x=document.getElementById(n); return x;
}

// javascript:merivatec_openImageDialog('images/beispiel.jpg','Beispiel',772,579);
function merivatec_openImageDialog(fileName,windowTitle,width,height)
{
 var fileToOpen = "imgdialog.php?imagefile="+fileName+"&title="+windowTitle;
 var options = "dependent=yes,width="+width+",height="+height+",location=no,menubar=no,resizable=no,scrollbars=no,status=no,toolbar=no,innerwidth="+width+",innerheight="+height;
 dialogWindow = window.open(fileToOpen,'Dialog',options);
 dialogWindow.resizeTo(width+10,height+29);
 dialogWindow.focus();
}

// javascript:merivatec_openDialog('beispiel.php','Beispiel',300,500);
function merivatec_openDialog(fileName,windowTitle,width,height)
{
 var options = "dependent=yes,width="+width+",height="+height+",location=no,menubar=no,resizable=no,scrollbars=no,status=no,toolbar=no,innerwidth="+width+",innerheight="+height;
 dialogWindow = window.open(fileName,'Dialog',options);
 dialogWindow.focus();
}

function merivatec_openFeatures(fileName,windowTitle,width,height)
{
 var options = "dependent=yes,width="+width+",height="+height+",location=no,menubar=no,resizable=yes,scrollbars=yes,status=no,toolbar=no,innerwidth="+width+",innerheight="+height;
 dialogWindow = window.open(fileName,'Dialog',options);
 dialogWindow.focus();
}

// onSubmit="if( !merivatec_validDomain(this.domain.value) ) { alert('Please enter a domain name'); return false; }"
function merivatec_validDomain( domain ) {

	if( domain == "IhreWunschdomain" ) {
		return false;
	}
	else if ( domain == "" ) {
		return false;
	}
	else {
		return true;
	}
	
}

// javascript:merivatec_openWindow('http://www.beispiel.de','Musterfenster');
function merivatec_openWindow(fileName,windowTitle)
{
 var options = "";
 normalWindow = window.open(fileName,'Window',options);
 normalWindow.focus();
}

// Alpha rollover script Copyright www.devmag.net
nereidFadeObjects = new Object();
nereidFadeTimers = new Object();

function nereidFade(object, destOp, rate, delta){

if (!document.all)
	return

if (object != "[object]"){
	setTimeout("nereidFade("+object+","+destOp+","+rate+","+delta+")",0);
	return;
	}

clearTimeout(nereidFadeTimers[object.sourceIndex]);
diff = destOp-object.filters.alpha.opacity;
direction = 1;

if (object.filters.alpha.opacity > destOp){
	direction = -1;
	}

delta=Math.min(direction*diff,delta);
object.filters.alpha.opacity+=direction*delta;

if (object.filters.alpha.opacity != destOp){
	nereidFadeObjects[object.sourceIndex]=object;
	nereidFadeTimers[object.sourceIndex]=setTimeout("nereidFade(nereidFadeObjects["+object.sourceIndex+"],"+destOp+","+rate+","+delta+")",rate);
	}
}
// End devmag.net rollover script