uboxlinks=0;uboxoben=0;uboxrechts=0;uboxunten=0;var fanzeigefilter="switchall";var tfelds="messdata";var smdiv="smileydiv";var titc=0;var titelorg=document.title;var tc;ex=0;ey=0;schluss=60000;
kuid = 0;
kodivarr = new Array();
anzkodivs = 0;
koposlinks = 0;
koposoben = 10;
letzteko = 0;
kochatarr = new Array();
chatarrcount = 0;
lastkochat = 0;
kochatreload = 1;
function klingklang()
{ 
  klkl = '<object type="application/x-shockwave-flash" data="sounds/emff_standard.swf" width="0" height="0"><param name="movie" value="sounds/emff_standard.swf"><param name="FlashVars" value="src=sounds/otheruserenters.mp3&amp;autostart=yes"></object>';
  document.getElementById ("sounddiv").innerHTML = klkl;
  stille = setTimeout("tonaus()", 5000);
}
function tonaus()
{
  document.getElementById ("sounddiv").innerHTML = "";
}
function removefchat(fchatid)
{
	var Knoten = document.getElementById("kod" + fchatid);
	verschwunden = document.getElementById("kommunikation").removeChild(Knoten);
	koposlinks = 0;
	koposoben = 0;
	for(i=0; i<kochatarr.length; i++)
	{
		einsetzen = kochatarr[i];
		if(document.getElementById("kod" + einsetzen))
		{
			document.getElementById("kod" + einsetzen).style.left = koposlinks + "%";
			document.getElementById("kod" + einsetzen).style.bottom = koposoben + "px";
			koposlinks+=20;
			if(koposlinks >= 100)
			{
				koposlinks = 0;
				koposoben += 25;
			}
		}
	}
	sendInfo("includes/fchat.php?chatpause." + fchatid, "kotempdiv", "");
}

function kochatauf(welcherkochat)
{
	document.getElementById("kod" + welcherkochat).className = "kchatdiv";
	document.getElementById("kod" + welcherkochat).style.height = 290 + "px";
	document.getElementById("msgalertimg" + welcherkochat).style.display = "none";
}

function koab(koabuid)
{
	sendInfo("includes/fchat.php?uid." + koabuid + "." + letzteko, "kotempdiv", document.getElementById("fchatform" + koabuid));

	kotempu = document.getElementById("fchatdiv" + koabuid).innerHTML;
	document.getElementById("fchatdiv" + koabuid).innerHTML = "Du:<div style='border-bottom:1px solid #CCCCCC; padding-bottom:3px; margin-bottom:3px;'>" + document.getElementById("fchatinput"+koabuid).value + "</div>" + kotempu;
	document.getElementById("fchatinput" + koabuid).value = "";
	return false;
}

function kommucheck()
{
	sendInfo("includes/fchat.php?" + lastkochat, "kotempdiv", "");
	kotimer = window.setTimeout("koeinbauen()", 2000)
	if(document.getElementById("kommunikation").innerHTML == "")
		document.getElementById("chatregler").style.display = "none";
	else
		document.getElementById("chatregler").style.display = "block";
	kochatreload = 0;
}

function initkochat()
{
	sendInfo("includes/fchat.php?start", "kotempdiv", "");
	kotimer = window.setTimeout("koeinbauen()", 2000);
}

function addchat(koname, kouid)
{
	if(!document.getElementById("kod" + kouid))
	{
		anzkodivs++;
		document.getElementById("kommunikation").innerHTML = document.getElementById("kommunikation").innerHTML + "<div id='kod" + kouid  + "' style='position:absolute; left:" + koposlinks + "%; bottom:" + koposoben + "px; width:24%; height:25px; overflow:hidden;' class='kchatdiv' onmouseover='kochatauf(" + kouid + ");' onmouseout='this.style.height=25" + '+"px"' + ";'><div style='padding:5px;'><a href='javascript:removefchat(" + kouid + ")'><img src='images/icons/delete_16x16.png' alt='1zu1 Chat mit diesem Mitglied schließen' style='float:right;' title='1zu1 Chat mit diesem Mitglied schließen' /></a><a href='steckbrief-von-" + koname + "-" + kouid + ".html' style='font-weight:900; font-size:12px;' title='Zum Steckbrief von " + koname + "'><img src='includes/zeigebild.php?" + kouid + ".1.20.0' style='vertical-align:middle;' />&nbsp;" + koname + "</a></div><div id='fchatdiv" + kouid + "' style='height:210px; overflow:auto; padding:5px;'></div><div><form id='fchatform" + kouid + "' action='' method='post' onsubmit='return koab(" + kouid + ")'><div style='float:left; width:80%;'><textarea id='fchatinput" + kouid + "' class='inputstart' style='width:100%; height:35px;' onkeydown='if(event.keyCode==13) koab(" + kouid + ");'></textarea></div><div style='float:left; width:20%; text-align:center;'><input type='image' src='images/icons/ok.png' id='fchatsubmit" + kouid + "' style='background:none; border:0px; height:24px; margin:5px 0 0 0;' /></div><div style='clear:both;'></div></form></div><img id='msgalertimg" + kouid + "' src='images/icons/hase.gif' alt='Neue Mitteilung' title='neue Mitteilung' style='position:absolute; top:2px; right:30px; display:none; height:20px;' /></div>";
		koposlinks+=25;
		if(koposlinks >= 100)
		{
			koposlinks = 0;
			koposoben += 25;
		}
		chatarrcount++;
		kochatarr[chatarrcount] = kouid;
	}
	document.getElementById("fbediv" + kouid).style.display = "none";
	document.getElementById("chatregler").style.display = "block";
}

function koeinbauen()
{
	if(document.getElementById("kotempdiv").innerHTML != "")
	{
		koparms=document.getElementById("kotempdiv").innerHTML.split("~");
		letztereintrag = koparms.length-1;
		lastkochat = koparms[letztereintrag];
		for(i=0; i<koparms.length-1; i++)
		{
			koparmsu = koparms[i].split("||");
			kochatid = koparmsu[0];
			if(!document.getElementById("kod" + kochatid))
			{
				anzkodivs++
				document.getElementById("kommunikation").innerHTML = document.getElementById("kommunikation").innerHTML + "<div id='kod" + kochatid  + "' style='position:absolute; left:" + koposlinks + "%; bottom:" + koposoben + "px; width:24%; height:25px; overflow:hidden;' class='" + (kochatreload == 0 ? "kchatdivalert" : "kchatdiv") + "' onmouseover='kochatauf(" + kochatid + ");' onmouseout='this.style.height=25" + '+"px"' + ";'><div style='padding:5px;'><a href='javascript:removefchat(" + kochatid + ")'><img src='images/icons/delete_16x16.png' alt='1zu1 Chat mit diesem Mitglied schließen' style='float:right;' title='1zu1 Chat mit diesem Mitglied schließen' /></a><a href='steckbrief-von-Freund-" + kochatid + ".html' style='font-weight:900; font-size:12px;' title='Zum Steckbrief'><img src='includes/zeigebild.php?" + kochatid + ".1.20.0' style='vertical-align:middle;' />&nbsp;" + koparmsu[3] + "</a></div><div id='fchatdiv" + kochatid + "' style='height:210px; overflow:auto; padding:5px;'>" + koparmsu[1] + "<div style='border-bottom:1px solid #CCCCCC; padding-bottom:3px; margin-bottom:3px;'>" + koparmsu[2] + "</div></div><div><form id='fchatform" + kochatid + "' action='' method='post' onsubmit='return koab(" + kochatid + ");'><div style='float:left; width:80%;'><textarea id='fchatinput" + kochatid + "' class='inputstart' style='width:100%; height:35px;'  onkeydown='if(event.keyCode==13) koab(" + kochatid + ");'></textarea></div><div style='float:left; width:20%; text-align:center;'><input type='image' src='images/icons/ok.png' id='fchatsubmit" + kochatid + "' style='background:none; border:0px; height:32px; margin:10px 0 0 0;' /></div><div style='clear:both;'></div></form></div><img id='msgalertimg" + kochatid + "' src='images/icons/hase.gif' alt='Neue Mitteilung' title='neue Mitteilung' style='position:absolute; top:2px; right:30px; display:block; height:20px;' /></div>";
				koposlinks+=25;
				if(koposlinks >= 100)
				{
					koposlinks = 0;
					koposoben += 25;
				}
				chatarrcount++;
				kochatarr[chatarrcount] = kochatid;
				if(kochatreload == 0) klingklang();
			}
			else
			{
				kotempu = document.getElementById("fchatdiv" + kochatid).innerHTML;
				document.getElementById("fchatdiv" + kochatid).innerHTML = koparmsu[1] + "<div style='border-bottom:1px solid #CCCCCC; padding-bottom:3px; margin-bottom:3px;'>" + koparmsu[2] + "</div>" + kotempu;
				if(koparmsu[1].substr(31,3) != "Du " && parseInt(document.getElementById("kod" + kochatid).style.height) < 100)
				{
					document.getElementById("kod" + kochatid).className = "kchatdivalert";
					document.getElementById("msgalertimg" + kochatid).style.display = "block";
					klingklang();
				}
			}
		}
	}
	if(document.getElementById("kotempdiv").innerHTML != "")
		document.getElementById("kommunikation").style.display = "block";
	document.getElementById("kotempdiv").innerHTML = "";
	if(document.getElementById("kommunikation").innerHTML == "")
		document.getElementById("chatregler").style.display = "none";
	else
		document.getElementById("chatregler").style.display = "block";
	kommucheck();
}

function neuladen(){if(schluss>0){nochsek=parseInt(schluss/1000);document.getElementById("achtungdiv").innerHTML="Achtung: in "+nochsek+" Sekunden wird die Seite neu geladen!!!";schluss-=1000;nsk=setTimeout("neuladen()",1000);}else{location.reload();}}function lblink(){curElements=document.getElementsByTagName("a");for(c=0;c<curElements.length;c++){if(document.getElementsByTagName("a")[c].className=="fbnblink"){if(document.getElementsByTagName("a")[c].style.color=="#000000"){document.getElementsByTagName("a")[c].style.color = "#990000";}else{document.getElementsByTagName("a")[c].style.color="#000000";}}}nfbblink=setTimeout("lblink()", 1000);}function zeigespecial(specialtitel,specialtext){if(document.getElementById("specialbox")){sv="<div class='spinnen'><h3>"+specialtitel+"</h3>"+"<div>"+specialtext+"</div></div>";document.getElementById("specialbox").innerHTML=sv;if(ex>800)eex=ex-100;else eex = ex;document.getElementById("specialbox").style.left=eex +"px";document.getElementById("specialbox").style.top=ey+10+"px";document.getElementById("specialbox").style.display="block";}}function pbildzoom(specialtext, w){if(document.getElementById("specialbox")){dims=Number(w)+6;sv="<div style=\'width:"+dims+"px; height:"+dims+"px; overflow:hidden;\'><img src=\'"+specialtext+"\' style=\'border:3px solid #0491d9; padding:0; margin:0;\' alt=\'\' /></div>";document.getElementById("specialbox").innerHTML=sv;if(ex>800)eex=ex-100;else eex = ex;document.getElementById("specialbox").style.left=eex+"px";document.getElementById("specialbox").style.top=ey+10+"px";document.getElementById("specialbox").style.display="block";}}function hidespecial(){if(document.getElementById("specialbox")){document.getElementById("specialbox").style.display="none";}}function delconfirmx(ctext){document.getElementById("blackbox").style.top=holevscroll()+"px";document.getElementById("blackbox").style.display="block";cf=window.confirm(ctext);document.getElementById("blackbox").style.display="none";return cf;}function delconfirm(dtext, ziel){cdiv = "<div class='eckeundschattenklein untertitel'><h2>Bitte bestätigen</h2></div><div class='quickmenucont' style='line-height:20px; margin-right:0px;'>" + dtext + "<div style='text-align:center; padding:10px;'><a class='inputstart button' href='includes/delitem.php?" + ziel + "' style='color:green; padding:0 5px 0 5px;'>Ja</a> <a class='inputstart button' href='javascript:hidebox();' style='color:red; padding:0 5px 0 5px;'>Nein</a></div></div>";document.getElementById("blackbox").style.top=holevscroll()+"px";document.getElementById("blackbox").style.display="block";document.getElementById("bildcont").style.width=500+"px";document.getElementById("bildcont").style.marginLeft=-250+"px";document.getElementById("continhalt").innerHTML=cdiv;hinweisbox();}function delconfirmhtml(ctext,funk,par){cdiv = "<div class='eckeundschattenklein untertitel'><h2>Bitte bestätigen</h2></div><div class='subdiv' style='line-height:20px;'>" + ctext + "<div style='text-align:center; padding:10px;'><span onclick='hidebox();"+funk+"("+par+");' style='color:green; cursor:pointer;'>Ja</span> <span onclick='hidebox();' style='color:red; cursor:pointer;'>Nein</span></div></div>";document.getElementById("blackbox").style.top = holevscroll()+"px";document.getElementById("blackbox").style.display="block";document.getElementById("bildcont").style.width=500+"px";document.getElementById("bildcont").style.marginLeft=-250+"px";document.getElementById("continhalt").innerHTML=cdiv;hinweisbox();}function hinweis(htext){hdiv="<div class='eckeundschattenklein untertitel'><h2>Hinweis</h2></div><div class='subdiv' style='line-height:20px;'>" + htext + "<div style='text-align:center; padding:10px;'><a class='inputstart button' href='javascript:hidebox()' style='color:green; padding:0 5px 0 5px;'>OK</a></div></div>";document.getElementById("blackbox").style.top=holevscroll()+"px";document.getElementById("blackbox").style.display="block";document.getElementById("bildcont").style.width=500+"px";document.getElementById("bildcont").style.marginLeft=-250+"px";document.getElementById("continhalt").innerHTML=hdiv;hinweisbox();}function holevscroll(){if(navigator.appName=="Netscape"){yv=eval(window.pageYOffset);}else{yv=eval(document.documentElement.scrollTop);}return yv;}function zeigebox(bild,profil){sendInfo("includes/zeigebild.php?"+bild+"."+profil+".850.0","bildcont","");document.getElementById("blackbox").style.top=holevscroll()+"px";document.getElementById("blackbox").style.display="block";document.getElementById("bildcont").style.top=50+holevscroll()+"px";document.getElementById("closeimg").style.top=40+holevscroll()+"px";document.getElementById("bildcont").style.display="block";document.getElementById("closeimg").style.display="block";}function hinweisbox(){document.getElementById("blackbox").style.height=100+"%";document.getElementById("blackbox").style.display="block";document.getElementById("bildcont").style.top=30+"px";document.getElementById("closeimg").style.top=30+"px";document.getElementById("bildcont").style.display="block";document.getElementById("closeimg").style.display="block";}function hidebox(){document.getElementById("blackbox").style.display="none";document.getElementById("bildcont").style.display="none";document.getElementById("closeimg").style.display="none";if(tc || typeof tc != "undefined"){window.clearTimeout(tc);document.title=titelorg;}}function mme(e){if(e){ex=e.pageX;ey=e.pageY;}else{ex=window.event.clientX;ey=window.event.clientY+holevscroll();}}document.onmousemove=mme;function bildoff(){if(ex<uboxlinks || ey<uboxoben || ex>uboxrechts || ey>uboxunten){document.getElementById("ubild").style.display="none";window.clearInterval(displaytimer);}}function bildon(bild){if(document.getElementById("ubild").style.display!="block"){document.getElementById("ubild").innerHTML="<img src='themes/wdf/images/warten.gif' alt='warten'  style='margin:40px;' />";if(ex>800)eex=ex-200;else eex=ex-100;uboxlinks=eex;uboxoben=ey-30;document.getElementById("ubild").style.left=eex+"px";if(navigator.appName!="Netscape")document.getElementById("ubild").style.top=uboxoben+"px";else document.getElementById("ubild").style.top=uboxoben+"px";if(navigator.appName!="Netscape" && navigator.appVersion.substring(0,1)=="8")document.getElementById("ubild").style.top=uboxoben+"px";uboxrechts=uboxlinks+280;uboxunten=uboxoben+120;document.getElementById("ubild").style.display="block";sendInfo("includes/visitenkarte.php?"+bild+".1.65.0","ubild","");displaytimer=window.setInterval("bildoff();",1000);}}function opacityb(id, millisec){var speed=Math.round(millisec/100);var timer=0;if(opacStart>opacEnd){for(i=opacStart;i>=opacEnd;i--){btimeout=setTimeout("changeOpacb("+i+",\'"+id+"\')",(timer*speed));stand=i;timer++;}}else if(opacStart<opacEnd){for(i=opacStart;i<=opacEnd;i++){btimeout=setTimeout("changeOpacb("+i+",\'"+id+"\')",(timer*speed));timer++;stand=i;}}}function changeOpacb(opacity,id){var object=document.getElementById(id).style;object.opacity=(opacity/100);object.MozOpacity=(opacity/100);object.KhtmlOpacity=(opacity/100);object.filter="alpha(opacity="+opacity+")";}function showhidediv(divicon,divid,timerstop,tfunc){if(document.getElementById(divid).style.display=="block"){document.getElementById(divid).style.display="none";if(divicon!="")document.getElementById(divicon).src="images/icons/plus.png";if(timerstop)sba=setTimeout(tfunc,10000);}else{document.getElementById(divid).style.display="block";if(divicon!="")document.getElementById(divicon).src="images/icons/minus.png";if(timerstop)window.clearTimeout(sba);}}function ereignischeck(){sendInfo("includes/ereignischeck.php","ereignisdiv","");}function freundecheck(){if(document.getElementById("offlinefiltern").checked==true)sendInfo("includes/freundecheck.php?f","fodiv","");else sendInfo("includes/freundecheck.php","fodiv","");}function changer(){if(titc==1){document.title="Neue Nachricht bei"+titelorg;titc=0;}else{document.title=titelorg;titc=1;}if(document.getElementById("blackbox").style.display=="block")var tc=window.setTimeout("changer()",1000);}function privmsgcheck(){if(document.getElementById("msgcheckdiv").innerHTML!=""&&document.getElementById("bildcont").style.display!="block"){pmparms=document.getElementById("msgcheckdiv").innerHTML.split(".");sendpm(pmparms[0],"",pmparms[1]);document.getElementById("msgcheckdiv").innerHTML="";changer();}sendInfo("includes/checkmessage.php?nurchecken","msgcheckdiv","");}function ncountcheck(){ccparms=document.getElementById("nzahlen").innerHTML.split("-");if(ccparms[0]!="0")document.getElementById("mailc").innerHTML="Email ("+ccparms[0]+")";else document.getElementById("mailc").innerHTML="Email";if(ccparms[1]!="0")document.getElementById("messc").innerHTML="Nachrichten ("+ccparms[1]+")";else document.getElementById("messc").innerHTML="Nachrichten";if(ccparms[2]!="0")document.getElementById("kussc").innerHTML="Erhaltene Küsse ("+ccparms[2]+")";else document.getElementById("kussc").innerHTML="Erhaltene Küsse";if(ccparms[3]!="0")document.getElementById("winksc").innerHTML="Erhaltene Winks ("+ccparms[3]+")";else document.getElementById("winksc").innerHTML="Erhaltene Winks";if(ccparms[4]!="0")document.getElementById("falink").innerHTML="<a href='freundschaftsanfragen.html' title='Zu Deinen Freundschaftsanfragen'>("+ccparms[4]+")</a>";document.getElementById("kussci").innerHTML="Küsse verwalten";document.getElementById("winksci").innerHTML="Winks verwalten";sendInfo("includes/sendkiss.php?checkonly","kisslist","");sendInfo("includes/sendwink.php?checkonly","winklist","");sendInfo("includes/checkzahlen.php","nzahlen","");}function onlinecount(){onlineseit++;onlinemin=Math.floor(onlineseit/60);onlinesek=onlineseit%60;document.getElementById("onlinezeit").innerHTML=onlinemin+" Min: "+onlinesek+" Sek.";}function getuser(usern,usernid){document.getElementById("pm_to_name").value=usern;document.getElementById("pm_to").value=usernid;document.getElementById("usuchdiv").style.display="none";}function usersuche(){document.getElementById("usuchdiv").style.display="block";sendInfo("includes/usersuchepm.php?"+document.getElementById("pm_to_name").value,"usuchdiv","");}function sendpm(pmid,pmname,messid, rl){if(!rl) rl="off";tfelds="messdata";smdiv="smileydiv";document.getElementById("bildcont").style.width=500+"px";document.getElementById("bildcont").style.marginLeft=-250+"px";if(messid!=0){sendInfo("includes/checkmessage.php?sendpm."+pmid+".answer."+messid +".rl."+rl,"continhalt","");}else{sendInfo("includes/checkmessage.php?sendpm."+pmid+".rl."+rl,"continhalt","");}hinweisbox();}function getpm(){sendInfo("includes/displaymessage.php?check","continhalt","");document.getElementById("bildcont").style.width=500+"px";document.getElementById("bildcont").style.marginLeft=-250+"px";hinweisbox();}function verstossform(vautor,waslink,wasid){document.getElementById("bildcont").style.width=500+"px";document.getElementById("bildcont").style.marginLeft=-250+"px";hinweisbox();sendInfo("includes/verstossmelden.php?"+vautor+"."+waslink+"."+wasid,"continhalt","");}function addtext(s,t,d,sd){document.getElementById(d).value=document.getElementById(d).value+" "+s+" ";switchdiv(d,sd);document.getElementById(d).focus();}function switchdiv(div1,div2){if(document.getElementById(div1).style.display=="block"){document.getElementById(div1).style.display="none";document.getElementById(div2).style.display="block";}else{document.getElementById(div1).style.display="block";document.getElementById(div2).style.display="none";}}function checkzeichen(ergdiv,checkdiv,maxzeichen){checktext=document.getElementById(checkdiv).value;if(maxzeichen)mz=maxzeichen;else mz=500;nz=mz-checktext.length;document.getElementById(ergdiv).innerHTML=nz;if(nz<1)document.getElementById(checkdiv).value=document.getElementById(checkdiv).value.substr(0,mz);}function bannerclick(bannerid){document.getElementById("bildcont").style.width=500+"px";document.getElementById("bildcont").style.marginLeft=-250+"px";hinweisbox();sendInfo("includes/countclicks.php?click."+bannerid,"continhalt","");return false;}lblink();
