if(self.scriptParsing) { scriptParsing("page"); }
var rnd=function(){return Math.round(Math.random()*999999)
};
function PoolEntity(b,m){this.win=window;
window.ilcsName="tmp";
this.available=function(){try{return !window.closed&&window.ilcsName&&window.document&&window.document.getElementsByTagName("body").length
}catch(c){return false
}};
if(!this.available()){DBG("ev: WARNING! current document not available")
}var F=this;
var l=function(G,H){if(!G){return false
}var c=false;
try{c=G.getIlcsObj(H)
}catch(I){}try{for(var w=0;
!c&&w<(G.frames||[]).length;
w++){c=l(G.frames[w],H)
}}catch(I){}return c
};
var g,f,A;
var t=this._setEntity=function(c,e){if(e){f[c]=e
}else{delete f[c]
}};
var h=function(c,e){t(c,e);
A(function(i){i._setEntity(c,e)
})
};
var n=this.getEntity=function(c){if(!c){for(var w in f){var H=n(w);
if(H){return H
}}return false
}var G=f[c];
if(!G){return false
}if(G.available&&G.available()){return G
}try{if(G.win){delete G.win.ilcsName
}}catch(H){}try{deleteCookie("ilcs_"+c)
}catch(H){}h(c);
if(F.entityLost){F.entityLost(c)
}return false
};
A=this.forEach=function(w){for(var c in f){var G=n(c);
if(G){w(G)
}}};
var q=this.getVal=function(c){return g[c]
};
var a=this.setVal=function(c,e){A(function(i){i._setVal(c,e)
})
};
this.chVal=function(e,i){var c=i(q(e));
a(e,c);
return c
};
this._setVal=function(c,e){g[c]=clone(e)
};
var s=l(top,b)||l(window.opener,b);
if(s){DBG("ev: pool with top/opener")
}var v=0;
var k=document.cookie.split("; ");
for(var x=0;
x<k.length;
x++){var C=k[x].split("=");
if(C[0].substr(0,5)!="ilcs_"){continue
}var u=parseInt(C[0].substr(5));
if(u>v){v=u
}if(s){continue
}var d=C[1].split(":");
var y=(d[0]&&d[0]!="*")?d[0]:C[0];
DBG("ev: cookie: "+k[x]+" -> "+y);
var o=false;
try{o=window.open("",y,"",false);
DBG("ev: -> "+(o?"found":"blocked"))
}catch(B){DBG("ev: -> except");
o=false
}if(o&&(s=l(o,b))){DBG("ev: pool from cookie "+k[x])
}else{if(!o||!l(o)){deleteCookie(C[0]);
if(o&&typeof(o)=="object"&&window!=o&&o.close){DBG("ev: reclosing");
try{o.close()
}catch(B){}}}}}var p=this.id=1+v;
var z="ilcs_"+p;
if(!s){DBG("ev: new pool");
s={udata:(m||{}),entities:{}}
}g=this.udata=clone(s.udata);
f=this.entities=clone(s.entities,true);
h(p,this);
window.ilcsName=b;
window.ilcsObj=this;
window.getIlcsObj=function(c){return(!c||this.ilcsName==c)?this.ilcsObj:false
};
try{top.name=z
}catch(B){}try{window.name=z
}catch(B){}var E=top.name||window.name||E;
if(E==z){E="*"
}DBG("ev: window.name: "+window.name+"");
this.cookie=function(c){c=E+(c?":"+c:"");
document.cookie=z+"="+c+"; path=/"
};
this.cookie();
var j=function(){};
var D=this.destroy=function(){DBG("ev: destroy");
if(F.onunload){F.onunload()
}F.stateChanged=j;
window.ilcsName=window.ilcsObj=false;
F.available=function(){return false
};
n(p)
};
window.addCallback("onunload",D)
}function getXmlHttp(){if(window.ActiveXObject){try{return new ActiveXObject("Msxml2.XMLHTTP")
}catch(a){}try{return new ActiveXObject("Microsoft.XMLHTTP")
}catch(a){}}if(typeof XMLHttpRequest!="undefined"){return new XMLHttpRequest()
}throw"Unable to obtain XmlHttp object"
}window.errorReload=function(f){if(window.errorReloading){DBG("ev: already reloading");
return
}window.errorReloading=true;
DBG("ev: reloading:",f);
var a=[],d=window.location.href.split("#");
var b=d[0].split("?");
if(b[1]){var g=b[1].split("&");
for(var c=0;
c<g.length;
c++){var e=g[c].split("=")[0];
if(e!="msg"&&e!="rnd"){a.push(g[c])
}}}if(f){a.push("msg="+encodeURIComponent(f))
}a.push("rnd="+rnd());
b=b[0]+"?"+a.join("&");
if(d[1]){b+="#"+d[1]
}window.location.href=b;
window.location.href=b
};
function EventConnection(g){var H=this;
var A=String.fromCharCode(1);
var J=String.fromCharCode(2);
var u=this.sep=String.fromCharCode(3);
var b=String.fromCharCode(4);
var a=String.fromCharCode(5);
this.stateChanged=function(L){DBG("ev: stateChanged: "+L);
var K;
if(L>=1&&(K=fetchProp(H,"modal"))){K.cancel()
}else{if(!L&!H.modal&&window.Modal){H.modal=new Modal({title:"Geen verbinding met de site",aboveWait:true,content:'Op dit moment kan er geen verbinding worden gemaakt met next·lover.<br /><br />Dit kan verschillende oorzaken hebben:<br /><ul><li>next·lover is down</li><li>Je internetverbinding is weggevallen</li><li>Er is een andere -misschien tijdelijke- fout opgetreden (<a href="javascript: refresh();">opnieuw proberen</a>)</li></ul>Dit bericht verdwijnt vanzelf wanneer de verbinding is hersteld ...</div>',finish:function(){var P=parseInt(this.root.style.left),O=parseInt(this.root.style.top),N=this.root.offsetWidth,M=this.root.offsetHeight;
this.degradeBox=document.createElement("div");
this.degradeBox.setAttribute("style","position: absolute; left: "+(P+9)+"px; top: "+(O+9)+"px; width: "+(N-18)+"px; height: "+(M-18)+"px; background: #f3f3f3; border: solid 3px #ffffff; z-index: 14900;");
document.body.appendChild(this.degradeBox);
return this.sup("finish")
},unfinish:function(){document.body.removeChild(this.degradeBox)
}}).schedule()
}}};
var f=[];
var n={};
var E={0:errorReload,1:true};
var y=99;
var x=function(N,K,M,O){DBG("ev: sending for entity "+(M||H.id)+": "+N);
if(f){f.push(arguments);
DBG("ev: delayed: still loading..");
return
}var L=H.chVal("reqSeqNr",function(P){return parseInt(P||0)+1
});
H.chVal("reqArr",function(P){P.push([L,""+(M||H.id)+J+N]);
return P
});
if(O){H.setVal("signing",true)
}if(!K||K<=0){q(true,K<0)
}};
function p(){DBG("ev: cancel");
var L={};
if(arguments.length>0){for(var K=0;
K<arguments.length;
K++){L[K]=this[arguments[K]]
}}else{L=this
}var M=[];
for(var K in L){if(!E[L[K]]){continue
}delete E[L[K]];
M.push(L[K])
}x("C"+M.join(J),1)
}var I=false;
this.send=function(){var O=arguments.length>1?arguments:arguments[0].split(u);
var L="",Q=O[0].split("|");
if(Q.length>1){L=J+Q[0];
Q=Q[1]
}else{Q=Q[0]
}var K={cancel:p};
var S=[];
for(var P=1;
P<O.length;
P++){var N,M=O[P];
if((typeof M!="object"||M===null||(typeof M[0]!="function"&&typeof M[1]!="function"))&&typeof(N=toJson(M))=="string"){S.push("j"+N)
}else{E[y+=1]=M;
S.push("c"+y);
K[P]=y
}}x((I?"I":"M")+"nextlover.nl|"+Q+u+S.join(u)+L,0,undefined,I);
I=false;
return K
};
this.signed=function(){I=true;
return this.send.apply(this,arguments)
};
this.resp=function(P){DBG("ev: resp:",P);
var K=parseInt(P.shift());
var L=P.shift();
var O,N=E[K];
if(!N){return
}for(var M=0;
M<P.length&&this.available&&this.available();
M++){var S=P[M].split(b);
if(S[0].charAt(0)==a){S[0]=S[0].substring(1);
if(S[S.length-1]===""){S.pop()
}S=xEval("["+S.join(",")+"]")
}try{O=callback(N,S)===true||O
}catch(Q){DBG("ev: caught response handling exception");
Q.detectMethod="evCb";
if(window.errReport){errReport(Q)
}else{setTimeout(function(){throw Q
},0)
}}}L=parseInt(n[K])+(L=="+"?1:(L=="-"?-1:parseInt(L)));
if(O&&L>=0){x("C"+K,1);
L=0
}if(L<0){delete E[K];
delete n[K]
}else{n[K]=L
}};
var G,m,i,C,B,w,D,v;
var o=false,q;
var c=function(){q()
};
var q=this.triggerMaster=function(K,M){if(o){clearTimeout(o)
}o=setTimeout(c,750);
var L=H.getVal("master");
if(L){L=H.getEntity(L)
}if(!L){DBG("ev: becoming master");
H.setVal("master",H.id);
L=H;
K=true;
G=true
}if(K){L.reconnectSoon(M)
}};
var F=function(){DBG("ev: stopMaster");
if(m){m.onreadystatechange=function(){};
m.abort()
}if(B){clearTimeout(B)
}if(w){clearTimeout(w)
}if(D){clearTimeout(D)
}G=m=B=w=D=0
};
this.entityLost=function(K){DBG("ev: entityLost "+K);
x("D",0,K);
if(K!=this.getVal("master")){return
}if(K==this.id){F()
}var L=this.getEntity();
if(L){L.triggerMaster()
}else{if(H.getVal("reqArr").length){G="unload";
C()
}}};
var l=function(L){var K=v;
v=L;
if(L==K||(L==1&&K>1)){return
}H.forEach(function(M){M.stateChanged(L)
})
};
var t=function(){w=0;
C()
};
var e=function(){l(0);
D=0;
C()
};
var d=function(){};
var s=0;
var k=function(S){DBG("ev: RESPONSE:",S);
if(D){clearTimeout(D);
D=0
}if(w){clearTimeout(w);
w=0
}var Q=(S||"").split(A);
var N=Q.shift().split(J);
var O=parseInt(N[1]);
var K=H.getVal("bid");
if(N[0]!="ilcs"){if(N[0].match(/running-in-maintenance-mode/)){return errorReload("maintenance")
}DBG("ev: invalid identifier (or no bid): "+N[0]);
if(s++){l(0)
}if(B){clearTimeout(B)
}B=setTimeout(C,3000);
return
}else{if(!O||(K&&K!=O)){DBG("ev: resync");
H.destroy();
H.forEach(function(W){if(H!=W){W.destroy();
W.win.errorReload("resync")
}});
H.destroy();
errorReload("resync");
return
}else{l(K?(K==O?1:3):2)
}}s=0;
H.cookie(O);
H.setVal("bid",O);
H.setVal("sec",N[2]);
var U=parseInt(N[3]);
H.chVal("reqArr",function(W){while(W.length&&U>=W[0][0]){W.shift()
}return W
});
if(!H.getVal("reqArr").length){H.setVal("signing",false)
}var T=3;
var V=T;
var M;
for(var P=0;
P<Q.length;
P++){r=Q[P].split(J);
if(!r[1]){continue
}M=r.shift();
var L=H.getEntity(parseInt(r.shift()));
if(L){L.resp(r)
}}DBG("ev: finished response proc");
if(M){H.setVal("lastResp",M)
}if(N[4]=="D"){DBG("ev: disconnect");
H.setVal("reqSeqNr",0);
H.setVal("bid",0);
H.setVal("sec",0);
H.setVal("lastResp",0);
if(H.getVal("reqArr").length){C()
}}else{C()
}};
var z=0;
var h=function(L){if(!m||L!=z||m.readyState!=4){return
}m.onreadystatechange=d;
var K=m.responseText;
m=0;
k(K)
};
C=function(){DBG("ev: reconnect");
if(B){clearTimeout(B);
B=0
}if(!G){DBG("ev: !isMaster");
return
}if(m){if(!i||(w&&i<2)){return DBG("ev: not aborting xhr")
}DBG("ev: aborting xhr");
m.onreadystatechange=function(){};
m.abort()
}i=0;
if(w){clearTimeout(w)
}w=setTimeout(t,500);
if(D){clearTimeout(D)
}D=setTimeout(e,35000);
var K="ilcb"+J+0+J+H.getVal("bid")+J+H.getVal("sec")+J+H.getVal("lastResp")+J+J+32+A;
var O=H.getVal("reqArr");
for(var M=0;
M<O.length;
M++){K+=""+O[M][0]+J+O[M][1]+A
}z+=1;
var S=z;
DBG("ev: REQUEST "+S+":",K);
var P=H.getVal("signing");
var L=g+(P?"Get":"")+"?r="+rnd();
try{m=getXmlHttp();
if(!m){throw 1
}m.open("POST",L,"sync"!=G);
if("sync"!=G){if(m.readyState==0){throw 2
}m.onreadystatechange=function(){h(S)
}
}m.send(K)
}catch(N){var Q=encodeURIComponent;
Q="_noxmlhttp?exception="+Q(N.toString())+"&url="+Q(g)+"&location="+Q(document.location.href);
document.location.href=Q
}};
this.start=function(){var K=f;
f=false;
for(var L=0;
L<K.length;
L++){x.apply(null,K[L])
}};
this.reconnectSoon=function(K){if(!i){i=1
}if(K){i=2;
C()
}else{if(!B){B=setTimeout(C,10)
}}};
var j={reqArr:[],reqSeqNr:0,bid:0,sec:0,lastResp:0};
PoolEntity.call(this,window.location.host+g,j)
}window.credits=0;
(function(){var g={basics:["emptyHtml"],attrs:{"class":"empty"}};
g.init=function(){this.list={}
};
g.ihtml=function(){return new InlineWidget(this.emptyHtml||"").render()
};
g.finish=function(){if(this.queue){for(var m=0;
m<this.queue.length;
m++){this.set.apply(this,this.queue[m])
}}this.queue=undefined
};
var b=function(n,o){var p=n.firstChild.nextSibling;
while(p&&o.order>p._listOrder){p=p.nextSibling
}if(o.element){if(p){n.insertBefore(o.element,p)
}else{n.appendChild(o.element)
}}else{var m=new InlineWidget(o.content).insert(n,p);
o.element=m.root;
delete o.content
}o.element._listOrder=o.order
};
var e=function(){var n=this.root.firstChild.style;
for(var m in this.list){if(this.list[m].length){this.root.delClass("empty");
n.display="none";
return
}}this.root.addClass("empty");
n.display="inline"
};
var d=function(p,o){var m=this.list[p];
if(!m){return
}for(var n=0;
n<m.length;
n++){if(m[n]===o){m.splice(n,1);
if(n){if(o.element){o.element.destruct()
}}else{o.element.remove();
if(m.length){b(this.root,m[0])
}}}}e.call(this)
};
g.set=function(s,t,o,u,v){if(!this.root){if(!this.queue){this.queue=[]
}this.queue.push(arguments);
return
}var w,m=this.list[s]=this.list[s]||[],q=0;
while(q<m.length&&v<m[q].priority){if(!m[q].timeout){return
}q++
}if(t){w={priority:v||0,order:o||0,content:(typeof t=="object")?t.render():t,timeout:!!u}
}if(u&&w){setCallbackTimeout([this,d,s,w],u)
}if(!q&&m[0]){m[0].element.parentNode.removeChild(m[0].element)
}var n=u?0:m.length-q;
for(var p=q;
p<q+n;
p++){if(m[p].element){$(m[p].element).destruct()
}}if(w){m.splice(q,n,w);
if(!q){b(this.root,w)
}}else{m.splice(q,n);
if(!m.length){delete this.list[s]
}}e.call(this)
};
var j=window.DynamicList=makeWidget(g);
var a=window.notifyEventList=new j({attrs:{"class":"notifyList notifyEventList"}});
var k=window.notifyStatusList=new j({attrs:{"class":"notifyList notifyStatusList"}});
window.notifyBlink=function(){};
var l=window.notify=function(n,s,o,t,m,q){var p=((m||0)<100);
if(s){if(typeof s=="object"){s=s.render()
}if(p){if(!q&&q!==false){q=R+(dd.png?"1/i/notify_info.png":"1/i/_gr.png")
}q=q?'<div style="float: left; padding-right: 2px; text-align: center;"><img src="'+q+'" style="display: inline;" /></div>':"";
s='<div style="margin: 0.25em 0 0.25em 0; clear: left;">'+q+"<div>"+s+"</div></div>"
}else{q=q?'<img src="'+q+'" style="margin-top: -4px;"/>':"";
s='<div style="margin: 0.25em 0 0.25em 0; clear: left;">'+s+" "+q+"</div>"
}}(p?a:k).set(n,s,m,o,t);
(p?k:a).set(n,false)
};
var c=window.notificationHandlers=watchExtensions.newWithProto();
var f=function(){var q="?";
var m=this.nextMatchValue;
if(parseInt(m)||m=="0"){var s=Math.round((this.nextMatchTimeStamp+m)-new Date().getTime()/1000);
if(s<1){s=0;
q="zodadelijk!"
}else{var p=Math.floor(s/60/60/24);
var o=Math.floor((s-p*(24*60*60))/60/60);
var n=Math.floor((s-p*(24*60*60)-o*(60*60))/60);
q="binnen ";
if(p>0){q+=p+"d "
}if(o>0){q+=o+"u "
}if(n>0&&!p){q+=n+"m "
}if(!o&&!p){q+=(Math.floor(s%60))+"s "
}}this.setVar("nextMatchSeconds",s)
}else{if(m=="off"){q="uitgeschakeld"
}else{if(m=="noCandidates"){q="geen candidaten"
}else{if(m=="questions"){q=false
}else{if(m=="calculating"){q="onbekend"
}else{if(m=="tooYoung"){q="niet toegestaan"
}}}}}}this.setVar("nextMatchText",q)
};
c.addWatch("nextMatchValue",function(){this.nextMatchTimeStamp=new Date().getTime()/1000;
if(this.nextMatchTimeout){clearTimeout(this.nextMatchTimeout)
}f.call(this)
});
c.addWatch("nextMatchText",function(){l("nextMatch",this.nextMatchText?new Link("matching",[showModal,"NextMatch"],"Klik hier om <i>direct</i> een nieuwe match te laten berekenen!").render()+": "+this.nextMatchText:false,false,20,105)
});
var h=function(){window.credits=this.credits;
if(this.userConfirmed){var m=new Link("credits",[showModal,"BuyCredits"],"Credits zijn in te zetten voor het gebruik van allerlei extra functionaliteit op de site. Klik om credits bij te kopen.").render()+": "+this.credits;
l("credits",m,false,20,120)
}else{l("credits",false)
}};
c.addWatch("credits",h);
c.addWatch("userConfirmed",function(){h.call(this)
});
c.msg=function(m,n,o){l(n||"msg",m,o||5000,90,0)
};
c.addWatch("promos","*",function(m,n){var o=new Link("Wake-up Light",showSweepstake).render()+": "+this.promos[n]+" lot"+((this.promos[n])==1?"":"en")+"";
l("promo_"+n,o,0,190,99,R+"1/i/bulb_small.gif")
});
c.addWatch("contacts","*",function(n,p){var u=this.contacts[p];
var m=false,q=false;
if(u&&u.name){var s=new Link(escapeHtml(u.name),window.toChat?[toChat,p,"focus"]:[s,"chat"]);
if(u.autoDel!=undefined&&u.autoDel!==false){m=s.render()+(u.autoDel?": nog "+u.autoDel+" dag"+((u.autoDel)==1?"":"en")+"":": vervalt vandaag");
q=R+(dd.png?"1/i/notify_remove.png":"1/i/_lq.png")
}else{if(u.msgs){if(this.initialized){var o=parseInt(new Date().getTime()/1000);
if((!u.lastSound||u.lastSound<o-30)&&u.msgs!=u._msgs){playSound("message")
}u.lastSound=o
}m=s.render()+": "+u.msgs+" bericht"+((u.msgs)==1?"":"en")+"";
q=R+(dd.png?"1/i/notify_msg.png":"1/i/_gs.png")
}else{if(u.qa){m=s.render()+": 1 q&a";
q=R+"1/i/question-mark.gif"
}else{if(u.ib){m=s.render()+": 1 antwoord";
q=R+(dd.png?"1/i/notify_ib.png":"1/i/_ew.png")
}}}}}if(u){u._msgs=u.msgs
}l("user_"+p,m,0,5,5,q)
});
c.addWatch("contacts","*","online",function(n,p){var q=this.contacts[p];
if(!q||q.online===undefined||!q.name||!this.initialized){return
}var o=q.photoUrl?'<img src="'+escapeHtmlString(q.photoUrl)+'" style="border: 2px solid white; float: right;" width="50" height="50" alt="" />':"";
var m=q.online?"<strong>"+escapeHtml(q.name)+"</strong> online":"<strong>"+escapeHtml(q.name)+"</strong> offline";
l("user_"+p,o+m+"<br style='clear: both;' />",5000,15,20,q.online?R+(dd.png?"1/i/notify_online.png":"1/i/_gt.png"):R+(dd.png?"1/i/notify_offline.png":"1/i/_gu.png"));
if(q.online){playSound("online")
}});
c.addWatch("contacts",function(){var p=0,m=0,o=0,q=0,t=0;
for(var n in this.contacts){var s=this.contacts[n];
if(!s.name){continue
}p+=s.msgs||0;
m+=(s.online?1:0);
o+=1;
if(s.feedback){q++;
if(!t){t=n
}}}this.setVarList({totalNewMsgs:p,totalContacts:o,onlineContacts:m,feedback:{count:q,id:t}})
});
c.addWatch("feedback",function(){var m=this.feedback;
var n=m.count>0?new Link("te beoordelen",window.toChat?[toChat,m.id,"focus"]:null).render()+": "+m.count:false;
l("feedback",n,0,20,60,R+(dd.png?"1/i/notify_feedback.png":"1/i/_ez.png"))
});
var i=function(){var m="nextlover.nl";
if(this.totalNewMsgs>0){m=""+this.totalNewMsgs+" NIEUW"+((this.totalNewMsgs)==1?"":"E")+" BERICHT"+((this.totalNewMsgs)==1?"":"EN")+" » "+m
}if(this.modalTitle){m=this.modalTitle+" » "+m
}if(this.subModalTitle){m=this.subModalTitle+" » "+m
}document.title=m
};
c.addWatch("totalNewMsgs",i);
c.addWatch("modalTitle",i);
c.addWatch("subModalTitle",i);
c.addWatch("anchorName",function(){var m="#"+(this.anchorName||"_");
if(document.location.href.slice(-m.length)!=m){document.location.href=m
}});
c.addWatch("iwn",function(){l("iwn",new Link("notifier",[showModal,"NotifierDownload"],"De Instant Web Notifier is een kleine applicatie waarmee je direct op de hoogte wordt gesteld van berichten en contacten die online komen, ook wanneer je niet bent ingelogd op de site.").render()+": "+(this.iwn?"actief!":"<em>niet</em> actief"),false,20,130)
});
c.photoClick=function(m,n){l("photoClick","Foto "+m+" keer positief beoordeeld!",5000,20,95,n)
}
})();
(function(){var a={name:"hiddenflash",url:"/multimedia.swf",flash:true};
if(dd.saf){window.addCallback("onSemiLoad",[loadCall,a,false])
}var b=function(d,c){if(!flashAvailable(6)){return
}if(!isLoaded(a)){loadCall(a,b,arguments);
return
}callFlash(gId("hiddenflash"),d,c)
};
window.playSound=function(d,c){switch(d){case"online":if(!(window.userFlags&16)){return
}d=R+"1/online.mp3";
break;
case"sd":if(!(window.userFlags&32)){return
}d=R+"1/sd.mp3";
break;
case"message":if(!(window.userFlags&64)){return
}d=R+"1/message.mp3";
break
}b(c?"streamAudio":"playAudio",d)
};
window.stopSounds=function(){b("stopAllAudio")
}
})();
function notifyAd(b,a){}function notMatchable(c,b){if(!c){return
}if(c=="autoMatching"){c="Matchen";
b="door de kunstmatige intelligentie gematcht te worden"
}var e=notificationHandlers&&((notificationHandlers.userConfirmed&&!notificationHandlers.userMatchable)||(!notificationHandlers.userConfirmed&&notificationHandlers.age<18));
var a,d=c+": "+(e?"niet mogelijk..":"alleen voor geregistreerde leden..");
if(e){a=new Modal({title:d,content:"Helaas: je moet minimaal <b>18 jaar</b> oud zijn om van next·lover gebruik te mogen maken"})
}else{a=new Modal({title:d,options:["Annuleren",false,"Inschrijven",function(){a.cancel();
showModal("Signup")
}]});
a.content=new InlineWidget("<br /><b>Registreer je nu gratis op "+("next·lover")+" om "+b+".</b><br /><br />Na registratie kun je:<ul><li><p>SpeedDaten & BattleDaten</p></li><li><p>Gematcht worden</p></li><li><p>OneLiners versturen & ontvangen</p></li><li><p>Je foto's laten beoordelen</p></li><li><p>.. en meer!</p></li></ul>Inschrijven kost je slechts enkele minuten!")
}a.show()
}function showMatchingResult(a,c,d){var b=new (getWidgetLoader(R+"12/j/matching.js","MatchingResult"))(c);
new Modal({modalId:a,title:"Nieuwe match!",preferredWidth:560,content:b.render(),onCancel:function(){this.close();
if(d){incrLoading();
ev.send("Match.wakeUp",d,decrLoading)
}}}).schedule()
}function showNeedToMeetRequest(a){incrLoading();
loadCall(R+"9/j/needToMeet.js",function(){new NeedToMeetRequestModal(a).schedule();
decrLoading()
})
}function showMatchingTurnedOff(a,c,d){var b=function(){var e=new MatchingTurnedOff(c,d);
new Modal({modalId:a,title:"Automatisch matchen staat uit",options:"Ja, matching aanzetten|ev.send('MatchServer.toggleAuto',true);|Nee|ev.send('MatchServer.enableRefused');",content:e.render()}).schedule()
};
loadCall(R+"12/j/matching.js",b)
}function showSweepstake(a){loadCall(R+"10/j/sweepstake.js",function(){new SweepstakeModal({modalId:a}).schedule()
})
}function modalDialog(d,c,b,a){new Modal({modalId:d,title:c,content:b,options:a}).schedule()
}function fancyModalDialog(d,c,b,a){modalDialog(d,c,fancyText(b),a)
}(function(){var a={textTop:15,right:25,textRight:5,borderLeft:25,top:181,borderRight:25,color:"#e50004",bottom:17,textLeft:5,cor:R+(dd.png?"1/i/_fz.png":"1/i/_g0.png"),inherit:AbstractMenu,left:25,ver:R+(dd.png?"1/i/_g1.png":"1/i/_g2.png")};
a.menuOptions=[[["Acties"],["match maken",[showModal,"NextMatch"],R+(dd.png?"1/i/menu_match_icon.png":"1/i/_g3.png"),"Wanneer krijg ik weer een nieuwe match? En wat als ik even geen matches meer erbij wil, of juist <i>nu</i> een match wil?",R+(dd.png?"1/i/scr_match.png":"1/i/_g4.png"),"m","nextMatch"],["SpeedDate zoeken",[loadCall,R+"16/j/speedDate.js",function(){window.sd.request(false)
}],R+(dd.png?"1/i/menu_sd_icon.png":"1/i/_g5.png"),function(){return"Vind direct iemand om mee te chatten! Een SpeedDate is een 5 minuten durende chat met iemand die nu online is. Na die tijd krijgen jullie beide de keuze om door te praten voor nog eens 10 minuten, en uiteindelijk ook om next·lover-contacten te worden."
},R+(dd.png?"1/i/scr_speeddate.png":"1/i/_g6.png"),"s","sd"],["BattleDate zoeken",[loadCall,R+"16/j/speedDate.js",function(){window.sd.request(true)
}],false,function(){return"Laat twee mensen vechten om jou! Een soort SpeedDate, maar dan anders: twee kandidaten 'vechten' in een 2-op-1 gesprek al chattend om de gunst van een derde persoon (jij!). Na afloop van de chat kan jij als initiatiefnemer kiezen met wie van de twee je verder wilt chatten. Het gesprek gaat dan over in een SpeedDate."
},R+(dd.png?"1/i/scr_battledate.png":"1/i/_g7.png"),"b","bd"],["foto's beoordelen..",[showModal,"PhotoQuestionDialog"],false,"Kies telkens uit twee foto's de foto die <b>jou</b> het meeste aanspreekt. De kunstmatige intelligentie leert hiervan te matchen aan mensen wiens uiterlijk je aanspreekt. Ook kun je, als je op slag verliefd wordt op één van de fotootjes, een OneLiner (kort berichtje) naar hem/haar sturen.",R+(dd.png?"1/i/scr_photorate.png":"1/i/_g8.png"),"o","photoQuestions"]],[["Profiel"],["foto's",[showModal,"Photos"],R+(dd.png?"1/i/menu_photos_icon.png":"1/i/_g9.png"),"Bekijk je foto's, plaats nieuwe, of verwijder oude.",R+(dd.png?"1/i/scr_photos.png":"1/i/_ga.png"),"f","photos"],["matching-vragen",[showModal,"QuestionGroups"],R+(dd.png?"1/i/menu_questions_icon.png":"1/i/_gb.png"),"Geef next·lover een duidelijker beeld van wie jij bent door meer vragen te beantwoorden (of door je eerdere antwoorden te herzien). Hoe vollediger en eerlijker de antwoorden, hoe beter je gematcht kan worden. Je antwoorden zijn niet zichtbaar voor anderen.",R+(dd.png?"1/i/scr_questions.png":"1/i/_gc.png"),"q","questions"],["do's &amp; don'ts",[showModal,"Tagging"],false,"Hou je enorm van sushi? Ben je een fan van coldplay? Is zeilen volledig jouw ding en kunnen toeristen je gestolen worden? Met do's &amp; don'ts laat je weten wat jij leuk, gaaf en hot vindt, en wat juist niet. Bij het matchen wordt hier rekening mee gehouden, zodat je een grotere kans hebt de enige  te ontmoeten die niets liever doet dan met jou naar een Coldplay-concert gaan om daarna lekker samen sushi te eten. Of met wie je op de Friese meren gezamenlijk kunt mopperen over al die zoetwater-toeristen.",R+(dd.png?"1/i/scr_tagging.png":"1/i/_gd.png"),"d","tagging"],["openingsvraag",[loadCall,R+"4/j/qa.js",[window,"showInitialQa",true]],false,"Klik hier om een openingsvraag te verzinnen. Deze vraag wordt automatisch voorgelegd aan elke nieuwe match, zodat je snel met diegene in een leuk gesprek verzeild kan raken!",false,false,"initialQa"]],[["Account"],["vrienden uitnodigen",[showModal,"InviteFriends"],R+(dd.png?"1/i/menu_invite_icon.png":"1/i/_ge.png"),"Heb je single vrienden? Vertel ze over next·lover! Zo help je de site met groeien, en verdien je ook nog eens credits. Wanneer je een uitnodiging stuurt naar iemand die al lid is, kun je elkaar toevoegen als next·lover-contacten.",R+(dd.png?"1/i/scr_invites.png":"1/i/_gf.png"),"u","inviteFriends"],["credits kopen",[showModal,"BuyCredits"],R+(dd.png?"1/i/menu_credits_icon.png":"1/i/_gg.png"),"Credits tekort? Vul ze hier aan (betaling via iDeal, creditcard of telefonisch). Je ondersteunt hiermee tevens de ontwikkeling van de site!",R+(dd.png?"1/i/scr_credits.png":"1/i/_gh.png"),"c","credits"],["vroegere contacten",[showModal,"FormerContacts"],false,"Hier vind je een overzichtje van verwijderde/geblokkeerde next·lover-contacten. Afhankelijk van de manier waarop iemand uit je lijstje verdwenen is, kan je hem/haar direct weer terugplaatsen, of een rematch-OneLiner sturen.",R+(dd.png?"1/i/scr_previous_contacts.png":"1/i/_gi.png"),"r","formerContacts"],["instellingen",[showModal,"SettingsDialog"],false,"Is je chat-naam niet goed? Geluidjes irritant? Teveel emailtjes? Deze, en vele andere dingen, kun je hier instellen. Ook als je je wilt uitschrijven van next·lover moet je hier zijn.",R+(dd.png?"1/i/scr_settings.png":"1/i/_gj.png"),"t","settings"],["uitloggen",[link,"logout"],false,"Uitgepaiqt? Kies dan deze optie. Als je volgende keer niet opnieuw wilt hoeven inloggen, kan je ook gewoon je browser sluiten, of naar een andere pagina navigeren om <i>offline</i> te gaan.",false,"x","logout"]],[["Info"],["help!?",[showModal,"Help"],R+(dd.png?"1/i/menu_help_icon.png":"1/i/_gk.png"),"Even de weg kwijt? Hier vind je een uitgebreide uitleg over allerlei zaken die met next·lover te maken hebben. Grote kans dat je antwoord vindt op je vraag!",R+(dd.png?"1/i/scr_help.png":"1/i/_gl.png"),"h","help"],["datingtips",[showModal,"TipsDialog"],false,"Online dating via next·lover is de ideale manier om contact te leggen met een toekomstige partner. Maar wees wel voorzichtig, je kunt mensen tegenkomen die zich anders voordoen dan ze zijn. We geven een paar tips over hoe je veilig kunt daten.",R+(dd.png?"1/i/scr_tips.png":"1/i/_gm.png"),null,"tips"],["contact",[showModal,"Contact"],false,"Klik hier indien je iets te bespreken hebt met de beheerders/makers van deze site.",R+(dd.png?"1/i/scr_help.png":"1/i/_gl.png"),null,"contact"]]];
a.attrs={"class":"action-menu"};
a.columnWidth=175;
a.documentCoverOpacity=0.55;
document.addCallback("onkeydown",function(c){c=c||window.event||{};
var b=getKeyCode(c);
if(b==27&&!window.menu.root){if(!window.templ||!window.templ.mainMenuEnabled){return
}window.menu.show();
return cancelEvent(c)
}if(c.altKey&&c.shiftKey&&b!=16&&b!=18){if(window.menu.handleKey(b)){return cancelEvent(c)
}}});
window.menu=new (makeWidget(a))();
window.menu.addColumn=function(b){this.menuOptions.push(b)
}
})();
window.adDim={width:336,height:280,floatWidth:341,floatHeight:193};
(function(){var d=makeWidget({ihtml:function(){var e=new ImageWidget({attrs:{onclick:'link("default")'},style:"margin-left: 10px; margin-top: 5px; margin-bottom: 5px; cursor: pointer;",data:{h:75,u:R+"1/i/logo.gif",w:194,l:0}});
this.content=""+e.render()+'<div style="position: absolute; left: 240px; top: 25px; width: 300px; font-size: 85%; color: #e3e3e3;"><span class="@onlineUserCountE">-</span> van de <span class="@totalUserCountE">-</span> next·lovers nu online,<br />waarvan <span class="@onlineContactsE">-</span> van jouw <span class="@totalContactsE">-</span> contacten<br /><span style=\'color: #ffffff;\'>powered by paiq.nl &amp; nrc·next</span></div> <div style="position: absolute; right: 14px; top: 2px;"><ul style="margin: 0; padding: 0; font-weight: bold; color: #ffffff;"><li style="display: inline;">'+(new Link({content:"help",onclick:[showModal,"Help"],style:"font-weight: bold; color: #ffffff;"}).render())+'</li><li style="display: inline; margin: 0 5px 0 5px;">|</li><li style="display: inline;">'+(new Link({content:"instellingen",onclick:[showModal,"Settings"],style:"font-weight: bold; color: #ffffff;"}).render())+'</li><li style="display: inline; margin: 0 5px 0 5px;">|</li><li style="display: inline;">'+(new Link({content:"uitloggen",onclick:[link,"logout"],style:"font-weight: bold; color: #ffffff;"}).render())+"</li></ul></div>";
return this.sup("ihtml")
}},HeaderBox);
var c=makeWidget({tag:"div",attrs:{style:"width: 100px; height: 100px; position: relative; margin-left: 42px;"},init:function(){if(window.notificationHandlers){notificationHandlers.addWatch("bestHeadshot",[this,this.redraw])
}},ihtml:function(){if(!window.notificationHandlers||!notificationHandlers.bestHeadshot||!notificationHandlers.bestHeadshot["100"]){return""
}return'<img class="@imageE" width="100" height="100" alt="" src="'+(escapeHtmlString(notificationHandlers.bestHeadshot["100"]))+'" style="position: absolute; top: 0; left: 0; z-index: 1;"/><img class="@rounderE" width="100" height="100" alt="" src="/d/2/i/photo_rounder.png" style="position: absolute; top: 0; left: 0; z-index: 2; cursor: pointer;"/>'
},finish:function(){if(this.rounderE){this.rounderE.addCallback("onclick",[showModal,"Photos"])
}}});
var b={tag:"span",attrs:{style:"width: 100%; height: 100%; background: #ffffff;"}};
b.ihtml=function(){var k=["voorwaarden",[showModal,"TosDialog"],"privacy",[showModal,"PrivacyDialog"],"datingtips",[showModal,"TipsDialog"],"nrc·next",[openWindow,"http://nrcnext.nl"]];
for(var e=[],f=0;
f<k.length;
f+=2){e.push(new Link(k[f],k[f+1]).render())
}var j=this.mainMenuEnabled?new c():null;
var l=window.notifyEventList?new InlineWidget('<div class="@usernameE" style=\'margin-left: 15px;\'><img src="/d/1/i/menu_active_arrow.gif" style="position: relative; top: -2px;" /> '+(new TitleFontWidget(username,"#e50004").render())+'</div><div style="margin: 0 0 0 16px; font-size: 85%; width: 185px; color: #e50004;" class="eventList">'+window.notifyEventList.render()+'</div><div style="margin: 0 0 0 23px; font-size: 85%; width: 185px; color: #e50004;" class="statusList">'+window.notifyStatusList.render()+"</div>"):null;
if(this.adEnabled&&1&&window.adDim){var g=window.adDim;
this.topAdWidget=new InlineWidget({style:"width: "+(g.width+10)+"px; height: "+(g.height+10)+"px; position: absolute; right: 15px; top: 15px; z-index: 50;",h:'<div style="position: relative; height: 100%; width: 100%; font-size: 70%; color: #808080; line-height: '+g.height+'px; text-align: center;">banner</div><iframe style="position: absolute; left: 0; top: 0; height: 100%; width: 100%; border: none; background: transparent;" border="0" frameborder="0" scrolling="no" class="@iframeE"></iframe>',tag:"div"})
}this.headerWidget=new d({style:"width: 100%;"});
if(this.mainMenuEnabled){var h=this;
this.goButton=new (makeWidget({textTop:1,right:8,content:"Doorgaan",borderLeft:25,top:15,borderRight:8,color:"#e90008",bottom:7,textLeft:20,transformContent:boxHelpers.t.basicButton,cor:R+(dd.png?"1/i/_gn.png":"1/i/_go.png"),inherit:Button,left:25,ver:R+(dd.png?"1/i/_gp.png":"1/i/_gq.png")}))({onclick:function(){window.menu.show();
if(h.goButton.root.blur){h.goButton.root.blur()
}},content:"   menu",large:true,style:"width: 160px; margin: 0 0 20px 13px; display: table;"})
}else{this.goButton=new (makeWidget({textTop:1,right:8,content:"Doorgaan",borderLeft:25,top:15,borderRight:8,color:"#e90008",bottom:7,textLeft:20,transformContent:boxHelpers.t.basicButton,cor:R+(dd.png?"1/i/_gn.png":"1/i/_go.png"),inherit:Button,left:25,ver:R+(dd.png?"1/i/_gp.png":"1/i/_gq.png")}))({onclick:[link,false],content:"   terug",large:true,style:"width: 160px; margin: 0 0 20px 13px; display: table;"})
}return'<span id="hiddenStuff" style="position: absolute; top: 0px; left: 0px"></span>  <div style=\'height: 100%; margin: 0 0 -33px 0; float: right; width: 1px; background-color: green;\'></div>    <div style=\'height: 25px; margin-right: 25px;\'></div>  <div style="margin-left: 13px; '+(this.topAdWidget?"margin-right: 380px;":"")+""+(dd.ie?"display: inline-block;":"")+'">'+this.headerWidget.render()+"</div> <div style='margin-right: 30px; "+(dd.ie?"display: inline-block;":"")+"'><table style='width: 100%;' cellpadding=\"0\" cellspacing=\"0\"><tr><td style='width: 235px; padding-top: 30px;'> "+(j?j.render():"")+" <div class='@leftColumnE' style='margin-top: 30px;'>"+this.goButton.render()+""+(l?l.render():"")+"</div></td><td>"+(typeof this.content=="object"?this.child("content"):this.content)+"</td></tr></table></div> "+(this.topAdWidget?this.topAdWidget.render():"")+' <div class="footerList" style="margin: 0 20px 0 20px; height: 20px; clear: both; padding: 3px 10px 0 0; border-top: solid 1px #c1c1c1; text-align: right; color: #848484; font-weight: bold;">'+(e.join(" | "))+"</div>"
};
var a=function(){var e=window.notificationHandlers;
if(e.onlineUserCount!=undefined){this.headerWidget.onlineUserCountE.innerHTML=e.onlineUserCount
}if(e.totalUserCount!=undefined){this.headerWidget.totalUserCountE.innerHTML=e.totalUserCount
}if(e.onlineContacts!=undefined){this.headerWidget.onlineContactsE.innerHTML=e.onlineContacts
}if(e.totalContacts!=undefined){this.headerWidget.totalContactsE.innerHTML=e.totalContacts
}};
b.finish=function(){if(window.notificationHandlers){var e=window.notificationHandlers;
e.addWatch("onlineUserCount",[this,a]);
e.addWatch("totalUserCount",[this,a]);
e.addWatch("onlineContacts",[this,a]);
e.addWatch("totalContacts",[this,a])
}window.menu.fromButton=this.goButton.root;
fixViewportY(this.leftColumnE,13);
if(this.topAdWidget){this.changeTopAd()
}};
b.unfinish=function(){};
b.changeTopAd=function(){if(!this.topAdWidget){return false
}try{this.topAdWidget.iframeE.setAttribute("src","/_ad_pcm?width="+this.adWidth+"&height="+this.adHeight+"")
}catch(f){}};
b.isTopAdVisible=function(){return this.topAdWidget&&(dd.ie?document.documentElement.scrollTop:window.pageYOffset)<220
};
window.SiteTemplate=makeWidget(b)
})();
var renderMenuMode=0;
var collapseTO=false;
(function(){var a={};
window.setAutoRunCloser=function(c,b){a[c]=b
};
window.autoRunKilled=function(b){callback(a[b]);
delete a[b]
};
window.killAutoRun=function(c,b){ev.send("AutoRun.kill",c);
if(!b){callback(a[c])
}if(b!=1){delete a[c]
}}
})();
window.oldAlert=window.alert;
window.alert=function(a){new Modal(0,a,"Let op!").show()
};
function viewPhotos(b,a){showModal("Photos",b,a)
}function showHistory(a,b){showPopup("_history?otherUserId="+a+""+(b?"&me="+b:"")+"#end")
}window.userTestFeature=function(c,b){var a=(window.euid||window.uid)+c*12345;
a+=(a<<12);
a^=(a>>22);
a+=(a<<4);
a^=(a>>9);
a+=(a<<10);
a^=(a>>2);
a+=(a<<7);
a^=(a>>12);
return a%(b||2)
};
var toAnchorHref=document.location.href;
window.toAnchor=function(){var b=toAnchorHref.split("#");
b.shift();
if(b[0]){var a=(b[0]=="RemoveAccount"||b[0]=="Settings");
triggerModal(a,b,true);
document.location.hash=b[0]
}};
function SitePage(){DBG("new SitePage");
this.auth=function(d,a,b){a=parseInt(a);
DBG("auth: "+d+" "+a+" "+b);
this.secret=b;
if(d){this.cookie=d;
document.cookie="a="+d+"; path=/; expires=Sun, 21-Apr-2030 00:00:01 GMT; domain="+domain+";";
DBG("setting cookie: a="+d+"; path=/; expires=Sun, 21-Apr-2030 00:00:01 GMT; domain="+domain+";")
}callback(this.onAuth);
if(a){this.onAuth=link
}};
this.stats=function(){};
window.ev=new EventConnection("/ilcs");
pageType=pageType||0;
this.start=function(){DBG("SitePage start: "+page+" "+pageType+" "+uid);
if(pageType&1&&page){incrLoading();
ev.send("init",page,[window.notificationHandlers,window.notificationHandlers.setVarList],uid)
}if(window.urlMsg){notify("urlMsg",escapeHtml(window.urlMsg),15000,0)
}ev.start();
window.fireCallback("onSemiLoad");
decrLoading()
};
this.cookie=getCookie("a");
if(!self.noLogin){ev.send("User.client",this.cookie,navigator.userAgent,this,(pageType==0?32:0),document.referrer,document.location.href)
}}window.addCallback("onload",function(){if(self.SymWinOpen&&document.location.href.indexOf("_firewall")<0){document.location.href="_firewall"
}});
(function(){var b;
var a=function(){b=false;
setTimeout(function(){b=true
},300000)
};
window.adEvent=function(){if(!b){return
}var c="/event/msg/ad_invisible";
if(window.templ.isTopAdVisible()){c="/event/msg/ad_visible";
window.templ.changeTopAd();
a()
}try{if(window.pageTracker){pageTracker._trackPageview(c)
}}catch(d){}};
a()
})();if(self.scriptReady) { scriptReady("page"); }
