support = "www.ad1.de";

if(top.frames.length > 0) top.location.href=self.location;

ie4 = (document.all) ? 1 : 0
n4 = ((navigator.userAgent.indexOf("Mozilla/4") >= 0) && (navigator.appName=="Netscape")) ? 1 : 0
nodom = 0;

dom = (document.getElementById) ? 1 : 0 ;
if(dom){
//	ie4 = 0;
} else {
	nodom = 1;
}

scw = screen.width-10
sch = screen.height-48
var startpos, endpos;
go = 0
scY = ""

function xmas(){window.open("telkomstress.html","EOY2002","toolbar=no,scrollbars=no,height=300,width=590");}

// function xmas(){window.open("sylv-eoy2001.html","EOY2001","toolbar=no,scrollbars=no,height=460,width=590");}

function byebye(){eval("window.open(\"byebye.html\",\"EOR2002\",\"toolbar=no,scrollbars=no,left=2,top=2,height="+sch+",width="+scw+"\")");}

	weite = 522 // 494 // 560
	hoehe = 294 //522 //  580 .. brunch

	dboh = 0

// ################################### //
/*
if(n4){
	window.captureEvents(Event.RESIZE);
	tis = this.location.href;
	window.onresize = reget;
}

function reget(){
this.location.href = tis
}
*/
// ################################### //



function wop(lg){
/**/
	Li = Math.floor(((scw-8)-weite)/2)
	Ob = Math.floor(((sch-54)-hoehe)/2)
	// alert(Ob); alert(weite); alert(hoehe); alert(Li)
// 	// 
eval("window.open(\""+lg+".html\",\"CNVS\",\"scrollbars=no,toolbars=no,status=no,width="+weite+",height="+hoehe+",left="+Li+",top="+Ob+"\")")

}

function wopcalidi(){
	Licd = Math.floor(((scw-8)-309)/2)
	Obcd = Math.floor(((sch-54)-444)/2)
	// alert(Ob); alert(weite); alert(hoehe); alert(Li)
// 	// 
eval("window.open(\"calidi.html\",\"CLD\",\"scrollbars=no,toolbars=no,status=no,width=309,height=444,left="+Licd+",top="+Obcd+"\")")
}

	weiteNL = 300
	hoeheNL = 300

function wopnl(){
	LiNL = Math.floor(((scw-8)-weiteNL)/2)
	ObNL = Math.floor(((sch-54)-hoeheNL)/2)
// 	
// 
eval("window.open(\"newsletter.html\",\"NL\",\"scrollbars=no,toolbars=no,status=no,width="+weiteNL+",height="+hoeheNL+",left="+LiNL+",top="+ObNL+"\")")
}

var	itm = "popup";

function showonce(){
/* z.Zt. nicht...*/
	if(self.name!=1)hinmit()
	self.name = 1

}


function hinmit(){

	if(dom) document.getElementById(itm).style.visibility = "visible"
	if(ie4) document.all[itm].style.visibility = "visible"
	//if(n4) document.itm.visibility = "show"

}

function wegmit(){

	if(dom) document.getElementById(itm).style.visibility = "hidden"
	if(ie4) document.all[itm].style.visibility = "hidden"
	//if(n4) document.itm.visibility = "hide"
}

// ###################################### //

function scsc(){
/*
if(go==1 && !n4){
			scY = document.body.scrollTop;
			lev = 	parseInt(document.getElementById("redII").style.top) + 10;
			histp = Math.floor((scY-lev)/3);
			if(scY > (startpos+1)){
				document.getElementById("redII").style.top = (scY < endpos) ? lev + histp : endpos;
			} else {
				document.getElementById("redII").style.top = startpos;
			}

//	window.status = lev 

}
*/	
}

// ################################### //

function prep(pObj,pSrc){
	if(document.images){
		eval(pObj+' = new Image()')
		eval(pObj+'.src = "'+pSrc+'"')
	}
}

prep('P11','../p/xx.gif')
prep('P10','../p/xo.gif')

// ###################################### //

function px(id,st){
	if(!n4)document.images["P"+id].src = eval("P"+id+st).src
}

// ###################################### //

var cr=0; var cor=support.split(""); for(var i=0; i<cor.length;i++)cr+=cor[i].charCodeAt(0); cr+=""; ky=parseInt(cr.substr(1,2));

// # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #

function loaded(){
/*
	if(termine==1){
		window.setTimeout('prospector()',111)
		window.setTimeout('go=1',222)
	}
*/
}

function style(css){cyc=0;re="";ret="";for(var i=0;i<css.length;++i){cyc++;if(cyc==1){re+=(parseInt(css.slice(i,i+2),16)-ky);ret+= String.fromCharCode(re);}if(cyc==2){cyc=0;re="";}}return ret;}

function prospector(){

	if(ie4){
		dboh = parseInt(document.all.toto.offsetHeight);
	} else {
		dboh = document.getElementsByTagName("body")[0].offsetHeight;
	}

/*	objH = parseInt(document.getElementById("redII").offsetHeight); */

	startpos = 110;
/*	endpos = dboh - startpos - objH - 320; // 320 = Sicherheitsabstand */
	// alert(endpos)

}
