(function(){var n="_gat",l="_gaq",au=true,av=false,aw=undefined,m=document,q="4.7.2",ar="length",aq="cookie",am="location",s="_gaUserPrefs",o="ioo",ak="&",al="=",ap="__utma=",an="__utmb=",ao="__utmc=",p="__utmk=",ae="__utmv=",ad="__utmz=",ai="__utmx=",f="GASO=";var aj=function(r){return aw==r||"-"==r||""==r},g=function(r){return r[ar]>0&&" \n\r\t".indexOf(r)>-1},ah=function(r,z,w){var y="-",v;if(!aj(r)&&!aj(z)&&!aj(w)){v=r.indexOf(z);if(v>-1){w=r.indexOf(w,v);if(w<0){w=r[ar]}y=ag(r,v+z.indexOf(al)+1,w)}}return y},e=function(r){var z=av,w=0,y,v;if(!aj(r)){z=au;for(y=0;y<r[ar];y++){v=r.charAt(y);w+="."==v?1:0;z=z&&w<=1&&(0==y&&"-"==v||".0123456789".indexOf(v)>-1)}}return z},J=function(r,w){var v=encodeURIComponent;return v instanceof Function?w?encodeURI(r):v(r):escape(r)},T=function(r,z){var w=decodeURIComponent,y;r=r.split("+").join(" ");if(w instanceof Function){try{y=z?decodeURI(r):w(r)}catch(v){y=unescape(r)}}else{y=unescape(r)}return y},E=function(r,v){return r.indexOf(v)>-1},I=function(r,v){r[r[ar]]=v},ac=function(r){return r.toLowerCase()},aa=function(r,v){return r.split(v)},j=function(r,v){return r.indexOf(v)},ag=function(r,w,v){v=aw==v?r[ar]:v;return r.substring(w,v)},k=function(r,v){return r.join(v)},h=function(r){var y=1,v=0,w;if(!aj(r)){y=0;for(w=r[ar]-1;w>=0;w--){v=r.charCodeAt(w);y=(y<<6&268435455)+v+(v<<14);v=y&266338304;y=v!=0?y^v>>21:y}}return y},i=function(){var r=window,v=aw;if(r&&r.gaGlobal&&r.gaGlobal.hid){v=r.gaGlobal.hid}else{v=ab();r.gaGlobal=r.gaGlobal?r.gaGlobal:{};r.gaGlobal.hid=v}return v},ab=function(){return Math.round(Math.random()*2147483647)},aH=function(r,w){var v=m.createElement("script");v.type="text/javascript";v.src=r;if(w){v.id=w}(m.getElementsByTagName("head")[0]||m.getElementsByTagName("body")[0]).appendChild(v)};var aF=function(r,v){this.Wa=r;this.jb=v},aG=function(){function r(z){var A=[];z=z.split(",");for(var y,w=0;w<z.length;w++){y=z[w].split(":");A.push(new aF(y[0],y[1]))}return A}var v=this;v.Ba="utm_campaign";v.Ca="utm_content";v.Da="utm_id";v.Ea="utm_medium";v.Fa="utm_nooverride";v.Ga="utm_source";v.Ha="utm_term";v.Ia="gclid";v.Y=0;v.z=0;v.Ma=15768000000;v.pb=1800000;v.w=63072000000;v.oa=[];v.qa=[];v.ac="cse";v.bc="q";v.kb=5;v.R=r("daum:q,eniro:search_word,naver:query,images.google:q,google:q,yahoo:p,msn:q,bing:q,aol:query,aol:encquery,lycos:query,ask:q,altavista:q,netscape:query,cnn:query,about:terms,mamma:query,alltheweb:q,voila:rdata,virgilio:qs,live:q,baidu:wd,alice:qs,yandex:text,najdi:q,aol:q,mama:query,seznam:q,search:q,wp:szukaj,onet:qt,szukacz:q,yam:k,pchome:q,kvasir:q,sesam:q,ozu:q,terra:query,mynet:q,ekolay:q,rambler:words");v.u=aw;v.hb=av;v.h="/";v.S=100;v.ja="/__utm.gif";v.aa=1;v.ba=1;v.v="|";v.$=1;v.Na=1;v.Ka=1;v.c="auto";v.G=1;v.ma=1000;v.wc=10;v.Hb=10;v.xc=0.2;v.o=aw;v.a=document;v.e=window};var c=function(w){function B(D,K,L,H){var F="",G=0;F=ah(D,"2"+K,";");if(!aj(F)){D=F.indexOf("^"+L+".");if(D<0){return["",0]}F=ag(F,D+L[ar]+2);if(F.indexOf("^")>0){F=F.split("^")[0]}L=F.split(":");F=L[1];G=parseInt(L[0],10);if(!H&&G<y.s){F=""}}if(aj(F)){F=""}return[F,G]}function A(D,F){return"^"+k([[F,D[1]].join("."),D[0]],":")}function r(D,F){var G=D+"; path="+v.h+"; "+F+y.ab();v.a[aq]=G}function z(D){var F=new Date;D=new Date(F.getTime()+D);return"expires="+D.toGMTString()+"; "}var y=this,v=w;y.s=(new Date).getTime();var C=[ap,an,ao,ad,ae,ai,f];y.k=function(){var D=v.a[aq];return v.o?y.Ob(D,v.o):D};y.Ob=function(D,H){var K=[],G,F;for(G=0;G<C[ar];G++){F=B(D,C[G],H)[0];aj(F)||(K[K[ar]]=C[G]+F+";")}return K.join("")};y.m=function(D,G,H){var F=H>0?z(H):"";if(v.o){G=y.Yb(v.a[aq],D,v.o,G,H);D="2"+D;F=H>0?z(v.w):""}r(D+G,F)};y.Yb=function(D,K,L,H,F){var G="";F=F||v.w;H=A([H,y.s+F*1],L);G=ah(D,"2"+K,";");if(!aj(G)){D=A(B(D,K,L,au),L);G=k(G.split(D),"");return G=H+G}return H};y.ab=function(){return aj(v.c)?"":"domain="+v.c+";"}};var d=function(z){function H(M){M=M instanceof Array?M.join("."):"";return aj(M)?"-":M}function D(O,P){var N=[],M;if(!aj(O)){N=O.split(".");if(P){for(M=0;M<N[ar];M++){e(N[M])||(N[M]="-")}}}return N}function v(P,Q,N){var M=F.K,O,R;for(O=0;O<M[ar];O++){R=M[O][0];R+=aj(Q)?Q:Q+M[O][4];M[O][2](ah(P,R,N))}}var C,B,y,K,L,G,w,F=this,A,r=z;F.j=new c(z);F.gb=function(){return aw==A||A==F.N()};F.k=function(){return F.j.k()};F.ha=function(){return L?L:"-"};F.sb=function(M){L=M};F.ua=function(M){A=e(M)?M*1:"-"};F.ga=function(){return H(G)};F.va=function(M){G=D(M)};F.Nb=function(){F.j.m(ae,"",-1)};F.Zb=function(){return A?A:"-"};F.ab=function(){return aj(r.c)?"":"domain="+r.c+";"};F.ea=function(){return H(C)};F.qb=function(M){C=D(M,1)};F.B=function(){return H(B)};F.ta=function(M){B=D(M,1)};F.fa=function(){return H(y)};F.rb=function(M){y=D(M,1)};F.ia=function(){return H(K)};F.tb=function(M){K=D(M);for(M=0;M<K[ar];M++){if(M<4&&!e(K[M])){K[M]="-"}}};F.Vb=function(){return w};F.qc=function(M){w=M};F.Kb=function(){C=[];B=[];y=[];K=[];L=aw;G=[];A=aw};F.N=function(){var M="",N;for(N=0;N<F.K[ar];N++){M+=F.K[N][1]()}return h(M)};F.pa=function(N){var O=F.k(),M=av;if(O){v(O,N,";");F.ua(F.N());M=au}return M};F.mc=function(M){v(M,"",ak);F.ua(ah(M,p,ak))};F.uc=function(){var N=F.K,O=[],M;for(M=0;M<N[ar];M++){I(O,N[M][0]+N[M][1]())}I(O,p+F.N());return O.join(ak)};F.Bc=function(P,Q){var N=F.K,M=r.h,O;F.pa(P);r.h=Q;for(O=0;O<N[ar];O++){aj(N[O][1]())||N[O][3]()}r.h=M};F.Ab=function(){F.j.m(ap,F.ea(),r.w)};F.ya=function(){F.j.m(an,F.B(),r.pb)};F.Bb=function(){F.j.m(ao,F.fa(),0)};F.Aa=function(){F.j.m(ad,F.ia(),r.Ma)};F.Cb=function(){F.j.m(ai,F.ha(),r.w)};F.za=function(){F.j.m(ae,F.ga(),r.w)};F.Dc=function(){F.j.m(f,F.Vb(),0)};F.K=[[ap,F.ea,F.qb,F.Ab,"."],[an,F.B,F.ta,F.ya,""],[ao,F.fa,F.rb,F.Bb,""],[ai,F.ha,F.sb,F.Cb,""],[ad,F.ia,F.tb,F.Aa,"."],[ae,F.ga,F.va,F.za,"."]]};var b=function(v){var B=this,z=v,A=new d(z),y=!u.Cc(),w=function(){},r=function(C){var D=(new Date).getTime(),F;F=(D-C[3])*(z.xc/1000);if(F>=1){C[2]=Math.min(Math.floor(C[2]*1+F),z.Hb);C[3]=D}return C};B.F=function(M,N,L,F,K,G){var C,D=z.G,H=z.a[am];A.pa(L);C=aa(A.B(),".");if(C[1]<500||F){if(K){C=r(C)}if(F||!K||C[2]>=1){if(!F&&K){C[2]=C[2]*1-1}C[1]=C[1]*1+1;M="?utmwv="+q+"&utmn="+ab()+(aj(H.hostname)?"":"&utmhn="+J(H.hostname))+(z.S==100?"":"&utmsp="+J(z.S))+M;if(0==D||2==D){F=2==D?w:G||w;y&&B.Ta(z.ja+M,F)}if(1==D||2==D){M=("https:"==H.protocol?"https://ssl.google-analytics.com/__utm.gif":"http://www.google-analytics.com/__utm.gif")+M+"&utmac="+N+"&utmcc="+B.Rb(L);if(a){M+="&gaq=1"}if(u.Va){M+="&aip=1"}y&&B.Ta(M,G)}}}A.ta(C.join("."));A.ya()};B.Ta=function(C,D){var F=new Image(1,1);F.src=C;F.onload=function(){F.onload=null;(D||w)()}};B.Rb=function(C){var D=[],H=[ap,ad,ae,ai],K,G=A.k(),F;for(K=0;K<H[ar];K++){F=ah(G,H[K]+C,";");if(!aj(F)){if(H[K]==ae){F=aa(F.split(C+".")[1],"|")[0];if(aj(F)){continue}F=C+"."+F}I(D,H[K]+F+";")}}return J(D.join("+"))}};var x=function(){var r=this;r.W=[];r.db=function(z){var w,y=r.W,v;for(v=0;v<y.length;v++){w=z==y[v].q?y[v]:w}return w};r.Gb=function(C,A,v,z,y,w,D,F){var B=r.db(C);if(aw==B){B=new x.Eb(C,A,v,z,y,w,D,F);I(r.W,B)}else{B.Ja=A;B.xb=v;B.wb=z;B.ub=y;B.Qa=w;B.vb=D;B.Sa=F}return B}};x.Db=function(v,B,z,A,y,w){var r=this;r.zb=v;r.wa=B;r.r=z;r.Oa=A;r.mb=y;r.nb=w;r.xa=function(){return"&"+["utmt=item","tid="+J(r.zb),"ipc="+J(r.wa),"ipn="+J(r.r),"iva="+J(r.Oa),"ipr="+J(r.mb),"iqt="+J(r.nb)].join("&utm")}};x.Eb=function(w,B,A,r,z,y,v,C){var D=this;D.q=w;D.Ja=B;D.xb=A;D.wb=r;D.ub=z;D.Qa=y;D.vb=v;D.Sa=C;D.P=[];D.Fb=function(M,N,L,F,G){var H=D.Wb(M),K=D.q;if(aw==H){I(D.P,new x.Db(K,M,N,L,F,G))}else{H.zb=K;H.wa=M;H.r=N;H.Oa=L;H.mb=F;H.nb=G}};D.Wb=function(H){var K,G=D.P,F;for(F=0;F<G.length;F++){K=H==G[F].wa?G[F]:K}return K};D.xa=function(){return"&"+["utmt=tran","id="+J(D.q),"st="+J(D.Ja),"to="+J(D.xb),"tx="+J(D.wb),"sp="+J(D.ub),"ci="+J(D.Qa),"rg="+J(D.vb),"co="+J(D.Sa)].join("&utmt")}};var aD=function(r){function A(){var D,K,L;K="ShockwaveFlash";var H="$version",C=w.d?w.d.plugins:aw;if(C&&C[ar]>0){for(D=0;D<C[ar]&&!L;D++){K=C[D];if(E(K.name,"Shockwave Flash")){L=K.description.split("Shockwave Flash ")[1]}}}else{K=K+"."+K;try{D=new ActiveXObject(K+".7");L=D.GetVariable(H)}catch(G){}if(!L){try{D=new ActiveXObject(K+".6");L="WIN 6,0,21,0";D.AllowScriptAccess="always";L=D.GetVariable(H)}catch(F){}}if(!L){try{D=new ActiveXObject(K);L=D.GetVariable(H)}catch(B){}}if(L){L=aa(L.split(" ")[1],",");L=L[0]+"."+L[1]+" r"+L[2]}}return L?L:v}var y=r,z=y.e,w=this,v="-";w.T=z.screen;w.La=!w.T&&z.java?java.awt.Toolkit.getDefaultToolkit():aw;w.d=z.navigator;w.U=v;w.sa=v;w.Pa=v;w.la=v;w.ka=1;w.Za=v;w.Sb=function(){var C;if(z.screen){w.U=w.T.width+"x"+w.T.height;w.sa=w.T.colorDepth+"-bit"}else{if(w.La){try{C=w.La.getScreenSize();w.U=C.width+"x"+C.height}catch(B){}}}w.la=ac(w.d&&w.d.language?w.d.language:w.d&&w.d.browserLanguage?w.d.browserLanguage:v);w.ka=w.d&&w.d.javaEnabled()?1:0;w.Za=y.ba?A():v;w.Pa=J(y.a.characterSet?y.a.characterSet:y.a.charset?y.a.charset:v)};w.vc=function(){return ak+"utm"+["cs="+J(w.Pa),"sr="+w.U,"sc="+w.sa,"ul="+w.la,"je="+w.ka,"fl="+J(w.Za)].join("&utm")};w.Qb=function(){var D=y.a,B=z.history[ar];D=w.d.appName+w.d.version+w.la+w.d.platform+w.d.userAgent+w.ka+w.U+w.sa+(D[aq]?D[aq]:"")+(D.referrer?D.referrer:"");for(var C=D[ar];B>0;){D+=B--^C++}return h(D)}};var t=function(w,B,A,r){function z(D){var F="";D=ac(D.split("://")[1]);if(E(D,"/")){D=D.split("/")[1];if(E(D,"?")){F=D.split("?")[0]}}return F}function y(D){var F="";F=ac(D.split("://")[1]);if(E(F,"/")){F=F.split("/")[0]}return F}var v=r,C=this;C.b=w;C.ob=B;C.s=A;C.cb=function(D){var F=C.da();return new t.t(ah(D,v.Da+al,ak),ah(D,v.Ga+al,ak),ah(D,v.Ia+al,ak),C.O(D,v.Ba,"(not set)"),C.O(D,v.Ea,"(not set)"),C.O(D,v.Ha,F&&!aj(F.I)?T(F.I):aw),C.O(D,v.Ca,aw))};C.fb=function(D){var F=y(D),G=z(D);if(E(F,"google")){D=D.split("?").join(ak);if(E(D,ak+v.bc+al)){if(G==v.ac){return au}}}return av};C.da=function(){var D,H=C.ob,K,G,F=v.R;if(!(aj(H)||"0"==H||!E(H,"://")||C.fb(H))){D=y(H);for(K=0;K<F[ar];K++){G=F[K];if(E(D,ac(G.Wa))){H=H.split("?").join(ak);if(E(H,ak+G.jb+al)){D=H.split(ak+G.jb+al)[1];if(E(D,ak)){D=D.split(ak)[0]}return new t.t(aw,G.Wa,aw,"(organic)","organic",D,aw)}}}}};C.O=function(D,F,G){D=ah(D,F+al,ak);return G=!aj(D)?T(D):!aj(G)?G:"-"};C.hc=function(D){var G=v.oa,H=av,F;if(D&&"organic"==D.Q){D=ac(T(D.I));for(F=0;F<G[ar];F++){H=H||ac(G[F])==D}}return H};C.bb=function(){var D="",F="";D=C.ob;if(!(aj(D)||"0"==D||!E(D,"://")||C.fb(D))){D=D.split("://")[1];if(E(D,"/")){F=ag(D,D.indexOf("/"));F=F.split("?")[0];D=ac(D.split("/")[0])}if(0==D.indexOf("www.")){D=ag(D,4)}return new t.t(aw,D,aw,"(referral)","referral",aw,F)}};C.$a=function(D){var F="";if(v.Y){F=D&&D.hash?D.href.substring(D.href.indexOf("#")):"";F=""!=F?F+ak:F}F+=D.search;return F};C.Tb=function(){return new t.t(aw,"(direct)",aw,"(direct)","(none)",aw,aw)};C.ic=function(D){var G=av,H,F=v.qa;if(D&&"referral"==D.Q){D=ac(J(D.V));for(H=0;H<F[ar];H++){G=G||E(D,ac(F[H]))}}return G};C.l=function(D){return aw!=D&&D.ib()};C.isNewCampaign=function(D){D=ah(D,ad+C.b+".",";");var F=D.split(".");D=new t.t;D.lb(F.slice(4).join("."));if(!C.l(D)){return true}F=v.a[am];F=C.$a(F);F=C.cb(F);if(!C.l(F)){F=C.da();C.l(F)||(F=C.bb())}return C.l(F)&&ac(D.J())!=ac(F.J())};C.getCampaignInformation=function(O,N){if(v.Na){var H="",M="-",K,F=0,G,L,D=C.b;if(O){L=O.k();H=C.$a(v.a[am]);if(v.z&&O.gb()){M=O.ia();if(!aj(M)&&!E(M,";")){O.Aa();return}}M=ah(L,ad+D+".",";");K=C.cb(H);if(C.l(K)){H=ah(H,v.Fa+al,ak);if("1"==H&&!aj(M)){return}}if(!C.l(K)){K=C.da();if(!aj(M)&&C.hc(K)){return}}if(!C.l(K)&&N){K=C.bb();if(!aj(M)&&C.ic(K)){return}}if(!C.l(K)){if(aj(M)&&N){K=C.Tb()}}if(C.l(K)){if(!aj(M)){F=M.split(".");G=new t.t;G.lb(F.slice(4).join("."));G=ac(G.J())==ac(K.J());F=F[3]*1}if(!G||N){L=ah(L,ap+D+".",";");G=L.lastIndexOf(".");L=G>9?ag(L,G+1)*1:0;F++;L=0==L?1:L;O.tb([D,C.s,L,F,K.J()].join("."));O.Aa()}}}}}};t.t=function(w,B,A,r,z,y,v){var C=this;C.q=w;C.V=B;C.Z=A;C.r=r;C.Q=z;C.I=y;C.Ra=v;C.J=function(){var D=[],G=[["cid",C.q],["csr",C.V],["gclid",C.Z],["ccn",C.r],["cmd",C.Q],["ctr",C.I],["cct",C.Ra]],H,F;if(C.ib()){for(H=0;H<G[ar];H++){if(!aj(G[H][1])){F=G[H][1].split("+").join("%20");F=F.split(" ").join("%20");I(D,"utm"+G[H][0]+al+F)}}}return D.join("|")};C.ib=function(){return !(aj(C.q)&&aj(C.V)&&aj(C.Z))};C.lb=function(D){var F=function(G){return T(ah(D,"utm"+G+al,"|"))};C.q=F("cid");C.V=F("csr");C.Z=F("gclid");C.r=F("ccn");C.Q=F("cmd");C.I=F("ctr");C.Ra=F("cct")}};var aE=function(w,C,A,r){function z(M,L,G){var H;if(!aj(G)){G=G.split(",");for(var K=0;K<G[ar];K++){H=G[K];if(!aj(H)){H=H.split(D);if(H[ar]==4){L[H[0]]=[H[1],H[2],M]}}}}}var y=this,v=C,D=al,F=w,B=r;y.L=A;y.na="";y.p={};y.gc=function(){var G;G=aa(ah(y.L.k(),ae+v+".",";"),v+".")[1];if(!aj(G)){G=G.split("|");z(1,y.p,G[1]);y.na=G[0];y.X()}};y.X=function(){y.Ib();var L=y.na,K,G,H="";for(K in y.p){if((G=y.p[K])&&1===G[2]){H+=K+D+G[0]+D+G[1]+D+1+","}}aj(H)||(L+="|"+H);if(aj(L)){y.L.Nb()}else{y.L.va(v+"."+L);y.L.za()}};y.rc=function(G){y.na=G;y.X()};y.pc=function(M,L,G,H){if(1!=H&&2!=H&&3!=H){H=3}var K=av;if(L&&G&&M>0&&M<=F.kb){L=J(L);G=J(G);if(L[ar]+G[ar]<=64){y.p[M]=[L,G,H];y.X();K=au}}return K};y.$b=function(G){if((G=y.p[G])&&1===G[2]){return G[1]}};y.Mb=function(H){var G=y.p;if(G[H]){delete G[H];y.X()}};y.Ib=function(){B._clearKey(8);B._clearKey(9);B._clearKey(11);var K=y.p,H,G;for(G in K){if(H=K[G]){B._setKey(8,G,H[0]);B._setKey(9,G,H[1]);(H=H[2])&&3!=H&&B._setKey(11,G,""+H)}}}};var af=function(){function A(P,Q,S,R){if(aw==z[P]){z[P]={}}if(aw==z[P][Q]){z[P][Q]=[]}z[P][Q][S]=R}function L(P,Q){if(aw!=z[P]&&aw!=z[P][Q]){z[P][Q]=aw;var S=au,R;for(R=0;R<K[ar];R++){if(aw!=z[P][K[R]]){S=av;break}}if(S){z[P]=aw}}}function F(P){var Q="",U=av,S,R;for(S=0;S<K[ar];S++){R=P[K[S]];if(aw!=R){if(U){Q+=K[S]}Q+=w(R);U=av}else{U=au}}return Q}function w(P){var Q=[],S,R;for(R=0;R<P[ar];R++){if(aw!=P[R]){S="";if(R!=O&&aw==P[R-1]){S+=R.toString()+r}S+=D(P[R]);I(Q,S)}}return y+Q.join(B)+H}function D(P){var Q="",U,S,R;for(U=0;U<P[ar];U++){S=P.charAt(U);R=G[S];Q+=aw!=R?R:S}return Q}var C=this,z={},M="k",N="v",K=[M,N],y="(",H=")",B="*",r="!",v="'",G={};G[v]="'0";G[H]="'1";G[B]="'2";G[r]="'3";var O=1;C.dc=function(P){return aw!=z[P]};C.D=function(){var P="",Q;for(Q in z){if(aw!=z[Q]){P+=Q.toString()+F(z[Q])}}return P};C.nc=function(P){if(P==aw){return C.D()}var Q=P.D(),R;for(R in z){if(aw!=z[R]&&!P.dc(R)){Q+=R.toString()+F(z[R])}}return Q};C._setKey=function(P,Q,R){if(typeof R!="string"){return av}A(P,M,Q,R);return au};C._setValue=function(P,Q,R){if(typeof R!="number"&&(aw==Number||!(R instanceof Number))||Math.round(R)!=R||R==NaN||R==Infinity){return av}A(P,N,Q,R.toString());return au};C._getKey=function(P,Q){return aw!=z[P]&&aw!=z[P][M]?z[P][M][Q]:aw};C._getValue=function(P,Q){return aw!=z[P]&&aw!=z[P][N]?z[P][N][Q]:aw};C._clearKey=function(P){L(P,M)};C._clearValue=function(P){L(P,N)}};var aC=function(r,w){var v=this;v.Fc=w;v.jc=r;v._trackEvent=function(A,z,y){return w._trackEvent(v.jc,A,z,y)}};var ax=function(A,K,F){function w(){if("auto"==G.c){var N=G.a.domain;if("www."==ag(N,0,4)){N=ag(N,4)}G.c=N}G.c=ac(G.c)}function D(){w();var O=G.c,N=O.indexOf("www.google.")*O.indexOf(".google.")*O.indexOf("google.");return N||"/"!=G.h||O.indexOf("google.org")>-1}function C(P,O,N){if(aj(P)||aj(O)||aj(N)){return"-"}P=ah(P,ap+H.b+".",O);if(!aj(P)){P=P.split(".");P[5]=P[5]?P[5]*1+1:1;P[3]=P[4];P[4]=N;P=P.join(".")}return P}function z(){return"file:"!=G.a[am].protocol&&D()}function L(N){if(!N||""==N){return""}for(;g(N.charAt(0));){N=ag(N,1)}for(;g(N.charAt(N[ar]-1));){N=ag(N,0,N[ar]-1)}return N}function M(Q,O,N,P){if(!aj(Q())){O(P?T(Q()):Q());E(Q(),";")||N()}}var H=this,y=aw,G=new aG,B=av,r=aw;H.e=window;H.r=A;H.s=Math.round((new Date).getTime()/1000);H.n=K||"UA-XXXXX-X";H.Ua=G.a.referrer;H.ca=aw;H.f=aw;H.M=aw;H.C=av;H.A=aw;H.g=aw;H.Xa=aw;H.b=aw;H.i=aw;G.o=F?J(F):aw;var v=function(P){var O,N=""!=P&&G.a[am].host!=P;if(N){for(O=0;O<G.u[ar];O++){N=N&&j(ac(P),ac(G.u[O]))==-1}}return N};H.lc=function(){if(!H.M){return null}var N=H.M.match(/^(?:\|([-0-9a-z.]{1,30})(?::(\d{4,5}))?\|)?([-.\w]{10,1200})$/i);if(!N){return null}return{domain:N[1]||null,port:N[2]||null,token:N[3]}};H.Xb=function(){return ab()^H.A.Qb()&2147483647};H.Ub=function(){if(!G.c||""==G.c||"none"==G.c){G.c="";return 1}w();return G.Ka?h(G.c):1};H.Pb=function(P,O){if(aj(P)){P="-"}else{O+=G.h&&"/"!=G.h?G.h:"";var N=P.indexOf(O);P=N>=0&&N<=8?"0":"["==P.charAt(0)&&"]"==P.charAt(P[ar]-1)?"-":P}return P};H.ra=function(P){var O="",N=G.a;O+=G.$?H.A.vc():"";O+=G.aa&&!aj(N.title)?"&utmdt="+J(N.title):"";O+="&utmhid="+i()+"&utmr="+J(H.ca)+"&utmp="+J(H.oc(P));return O};H.oc=function(O){var N=G.a[am];return O=aw!=O&&""!=O?J(O,au):J(N.pathname+N.search,au)};H.yc=function(O){if(H.H()){var N="";if(H.g!=aw&&H.g.D()[ar]>0){N+="&utme="+J(H.g.D())}N+=H.ra(O);y.F(N,H.n,H.b)}};H.Lb=function(){var N=new d(G);return N.pa(H.b)?N.uc():aw};H._getLinkerUrl=function(Q,O){var N=Q.split("#"),P=Q,R=H.Lb();if(R){if(O&&1>=N[ar]){P+="#"+R}else{if(!O||1>=N[ar]){if(1>=N[ar]){P+=(E(Q,"?")?ak:"?")+R}else{P=N[0]+(E(Q,"?")?ak:"?")+R+"#"+N[1]}}}}return P};H.sc=function(){var P=H.lc();if(P){H.i.qc(H.M);H.i.Dc();u._gasoDomain=G.c;u._gasoCPath=G.h;var O="www.google.com";if(P.domain){O=P.domain+".google.com"+(P.port?":"+P.port:"")}var N="https://www.google.com/analytics/reporting/overlay_js?gaso=";if(P.domain){N="https://"+O+"/analytics/reporting/overlay_js?gaso="}N+=P.token+ak+ab();aH(N,"_gasojs")}};H.cc=function(){var X=H.s,N=H.i,U=N.k(),O=H.b+"",R=G.e,Y=R?R.gaGlobal:aw,V,W=E(U,ap+O+"."),S=E(U,an+O),Q=E(U,ao+O),P,aJ=[],aI="",Z=av;U=aj(U)?"":U;if(G.z){V=G.a[am]&&G.a[am].hash?G.a[am].href.substring(G.a[am].href.indexOf("#")):"";if(G.Y&&!aj(V)){aI=V+ak}aI+=G.a[am].search;if(!aj(aI)&&E(aI,ap)){N.mc(aI);N.gb()||N.Kb();P=N.ea()}M(N.ha,N.sb,N.Cb,true);M(N.ga,N.va,N.za)}if(aj(P)){if(W){if(!S||!Q||0){P=C(U,";",X);H.C=au}else{P=ah(U,ap+O+".",";");aJ=aa(ah(U,an+O,";"),".")}}else{P=k([O,H.Xb(),X,X,X,1],".");Z=H.C=au}}else{if(aj(N.B())||aj(N.fa())){P=C(aI,ak,X);H.C=au}else{aJ=aa(N.B(),".");O=aJ[0]}}P=P.split(".");if(R&&Y&&Y.dh==O&&!G.o){P[4]=Y.sid?Y.sid:P[4];if(Z){P[3]=Y.sid?Y.sid:P[4];if(Y.vid){X=Y.vid.split(".");P[1]=X[0];P[2]=X[1]}}}N.qb(P.join("."));aJ[0]=O;aJ[1]=aJ[1]?aJ[1]:0;aJ[2]=aw!=aJ[2]?aJ[2]:G.wc;aJ[3]=aJ[3]?aJ[3]:P[4];N.ta(aJ.join("."));N.rb(O);aj(N.Zb())||N.ua(N.N());N.Ab();N.ya();N.Bb()};H.ec=function(){y=new b(G)};H._getName=function(){return H.r};H._initData=function(){var N;if(!B){if(!H.A){H.A=new aD(G);H.A.Sb()}H.b=H.Ub();H.i=new d(G);H.g=new af;r=new aE(G,H.b,H.i,H.g);H.ec()}if(z()){if(!B){H.ca=H.Pb(H.Ua,G.a.domain);N=new t(H.b,H.ca,H.s,G)}H.cc(N);r.gc()}if(!B){z()&&N.getCampaignInformation(H.i,H.C);H.Xa=new af;B=au}H.fc()};H._visitCode=function(){H._initData();var N=ah(H.i.k(),ap+H.b+".",";");N=N.split(".");return N[ar]<4?"":N[1]};H._cookiePathCopy=function(N){H._initData();H.i&&H.i.Bc(H.b,N)};H.fc=function(){if(!u.eb){var N=G.a[am].hash;if(N&&1==N.indexOf("gaso=")){N=ah(N,"gaso=",ak)}else{N=(N=G.e.name)&&0<=N.indexOf("gaso=")?ah(N,"gaso=",ak):ah(H.i.k(),f,";")}if(N[ar]>=10){H.M=N;H.sc()}u.eb=au}};H.H=function(){return H._visitCode()%10000<G.S*100};H.tc=function(){var P,O,N=G.a.links;if(!G.hb){P=G.a.domain;if("www."==ag(P,0,4)){P=ag(P,4)}G.u.push("."+P)}for(P=0;P<N[ar]&&(G.ma==-1||P<G.ma);P++){O=N[P];if(v(O.host)){if(!O.gatcOnclick){O.gatcOnclick=O.onclick?O.onclick:H.kc;O.onclick=function(Q){var R=!this.target||this.target=="_self"||this.target=="_top"||this.target=="_parent";R=R&&!H.Jb(Q);H.zc(Q,this,R);return R?av:this.gatcOnclick?this.gatcOnclick(Q):au}}}}};H.kc=function(){};H._trackPageview=function(N){if(z()){H._initData();G.u&&H.tc();H.yc(N);H.C=av}};H._trackTrans=function(){var Q=H.b,O=[],N,P,R;H._initData();if(H.f&&H.H()){for(N=0;N<H.f.W[ar];N++){P=H.f.W[N];I(O,P.xa());for(R=0;R<P.P[ar];R++){I(O,P.P[R].xa())}}for(N=0;N<O[ar];N++){y.F(O[N],H.n,Q,au)}}};H._setTrans=function(){var Q=G.a,O,N,P;Q=Q.getElementById?Q.getElementById("utmtrans"):Q.utmform&&Q.utmform.utmtrans?Q.utmform.utmtrans:aw;H._initData();if(Q&&Q.value){H.f=new x;P=Q.value.split("UTM:");G.v=!G.v||""==G.v?"|":G.v;for(Q=0;Q<P[ar];Q++){P[Q]=L(P[Q]);O=P[Q].split(G.v);for(N=0;N<O[ar];N++){O[N]=L(O[N])}if("T"==O[0]){H._addTrans(O[1],O[2],O[3],O[4],O[5],O[6],O[7],O[8])}else{"I"==O[0]&&H._addItem(O[1],O[2],O[3],O[4],O[5],O[6])}}}};H._addTrans=function(U,N,Q,O,P,V,R,S){H.f=H.f?H.f:new x;return H.f.Gb(U,N,Q,O,P,V,R,S)};H._addItem=function(R,O,N,P,S,U){var Q;H.f=H.f?H.f:new x;(Q=H.f.db(R))||(Q=H._addTrans(R,"","","","","","",""));Q.Fb(O,N,P,S,U)};H._setVar=function(N){if(N&&""!=N&&D()){H._initData();r.rc(J(N));H.H()&&y.F("&utmt=var",H.n,H.b)}};H._setCustomVar=function(Q,O,N,P){H._initData();return r.pc(Q,O,N,P)};H._deleteCustomVar=function(N){H._initData();r.Mb(N)};H._getVisitorCustomVar=function(N){H._initData();return r.$b(N)};H._setMaxCustomVariables=function(N){G.kb=N};H._link=function(O,N){if(G.z&&O){H._initData();G.a[am].href=H._getLinkerUrl(O,N)}};H._linkByPost=function(O,N){if(G.z&&O&&O.action){H._initData();O.action=H._getLinkerUrl(O.action,N)}};H._setXKey=function(P,O,N){H.g._setKey(P,O,N)};H._setXValue=function(P,O,N){H.g._setValue(P,O,N)};H._getXKey=function(O,N){return H.g._getKey(O,N)};H._getXValue=function(O,N){return H.g.getValue(O,N)};H._clearXKey=function(N){H.g._clearKey(N)};H._clearXValue=function(N){H.g._clearValue(N)};H._createXObj=function(){H._initData();return new af};H._sendXEvent=function(O){var N="";H._initData();if(H.H()){N+="&utmt=event&utme="+J(H.g.nc(O))+H.ra();y.F(N,H.n,H.b,av,au)}};H._createEventTracker=function(N){H._initData();return new aC(N,H)};H._trackEvent=function(Q,O,N,P){H._initData();var R=H.Xa;if(aw!=Q&&aw!=O&&""!=Q&&""!=O){R._clearKey(5);R._clearValue(5);(Q=R._setKey(5,1,Q)&&R._setKey(5,2,O)&&(aw==N||R._setKey(5,3,N))&&(aw==P||R._setValue(5,1,P)))&&H._sendXEvent(R)}else{Q=av}return Q};H.zc=function(Q,O,N){H._initData();if(H.H()){var P=new af;P._setKey(6,1,O.href);var R=N?function(){H.Ya(Q,O)}:aw;y.F("&utmt=event&utme="+J(P.D())+H.ra(),H.n,H.b,av,au,R);N&&G.e.setTimeout(function(){H.Ya(Q,O)},500)}};H.Ya=function(P,O){if(!P){P=G.e.event}var N=au;if(O.gatcOnclick){N=O.gatcOnclick(P)}if(N||typeof N=="undefined"){if(!O.target||O.target=="_self"){G.e[am]=O.href}else{if(O.target=="_top"){G.e.top.document[am]=O.href}else{if(O.target=="_parent"){G.e.parent.document[am]=O.href}}}}};H.Jb=function(O){if(!O){O=G.e.event}var N=O.shiftKey||O.ctrlKey||O.altKey;if(!N){if(O.modifiers&&G.e.Event){N=O.modifiers&G.e.Event.CONTROL_MASK||O.modifiers&G.e.Event.SHIFT_MASK||O.modifiers&G.e.Event.ALT_MASK}}return N};H.Ec=function(){return G};H._setDomainName=function(N){G.c=N};H._addOrganic=function(P,O,N){G.R.splice(N?0:G.R.length,0,new aF(P,O))};H._clearOrganic=function(){G.R=[]};H._addIgnoredOrganic=function(N){I(G.oa,N)};H._clearIgnoredOrganic=function(){G.oa=[]};H._addIgnoredRef=function(N){I(G.qa,N)};H._clearIgnoredRef=function(){G.qa=[]};H._setAllowHash=function(N){G.Ka=N?1:0};H._setCampaignTrack=function(N){G.Na=N?1:0};H._setClientInfo=function(N){G.$=N?1:0};H._getClientInfo=function(){return G.$};H._setCookiePath=function(N){G.h=N};H._setTransactionDelim=function(N){G.v=N};H._setCookieTimeout=function(N){H._setCampaignCookieTimeout(N*1000)};H._setCampaignCookieTimeout=function(N){G.Ma=N};H._setDetectFlash=function(N){G.ba=N?1:0};H._getDetectFlash=function(){return G.ba};H._setDetectTitle=function(N){G.aa=N?1:0};H._getDetectTitle=function(){return G.aa};H._setLocalGifPath=function(N){G.ja=N};H._getLocalGifPath=function(){return G.ja};H._setLocalServerMode=function(){G.G=0};H._setRemoteServerMode=function(){G.G=1};H._setLocalRemoteServerMode=function(){G.G=2};H._getServiceMode=function(){return G.G};H._setSampleRate=function(N){G.S=N};H._setSessionTimeout=function(N){H._setSessionCookieTimeout(N*1000)};H._setSessionCookieTimeout=function(N){G.pb=N};H._setAllowLinker=function(N){G.z=N?1:0};H._setAllowAnchor=function(N){G.Y=N?1:0};H._setCampNameKey=function(N){G.Ba=N};H._setCampContentKey=function(N){G.Ca=N};H._setCampIdKey=function(N){G.Da=N};H._setCampMediumKey=function(N){G.Ea=N};H._setCampNOKey=function(N){G.Fa=N};H._setCampSourceKey=function(N){G.Ga=N};H._setCampTermKey=function(N){G.Ha=N};H._setCampCIdKey=function(N){G.Ia=N};H._getAccount=function(){return H.n};H._setAccount=function(N){H.n=N};H._setNamespace=function(N){G.o=N?J(N):aw};H._getVersion=function(){return q};H._setAutoTrackOutbound=function(N){G.u=[];if(N){G.u=N}};H._setTrackOutboundSubdomains=function(N){G.hb=N};H._setHrefExamineLimit=function(N){G.ma=N};H._setReferrerOverride=function(N){H.Ua=N};H._setCookiePersistence=function(N){H._setVisitorCookieTimeout(N)};H._setVisitorCookieTimeout=function(N){G.w=N}};var aA=function(){var r=this;r.Va=av;r.yb={};r.Ac=0;r.eb=av;r._gasoDomain=aw;r._gasoCPath=aw;r._getTracker=function(w,v){return r._createTracker(w,aw,v)};r._createTracker=function(y,v,w){if(v==aw){v="~"+u.Ac++}return u.yb[v]=new ax(v,y,w)};r._getTrackerByName=function(v){v=v||"";return u.yb[v]||u._createTracker(undefined,v)};r.Cc=function(){var v=window[s];return v&&v[o]&&v[o]()};r._anonymizeIp=function(){r.Va=au}};var a=av,ay=function(){var r=this;r._createAsyncTracker=function(w,v){return u._createTracker(w,v||"")};r._getAsyncTracker=function(v){return u._getTrackerByName(v)};r.push=function(){var B=arguments,A=0;a=au;for(var v=0;v<B[ar];v++){try{if(typeof B[v]==="function"){B[v]()}else{var z="",y=B[v][0],w=y.lastIndexOf(".");if(w>0){z=ag(y,0,w);y=ag(y,w+1)}var C=z==n?u:z==l?aB:u._getTrackerByName(z);C[y].apply(C,B[v].slice(1))}}catch(D){A++}}return A}};function az(){var r=window[n];if(r&&typeof r._getTracker=="function"){u=r}else{window[n]=u}}function at(){var r=window[l],v=av;if(r&&typeof r.push=="function"){v=r.constructor==Array;if(!v){return}}window[l]=aB;v&&aB.push.apply(aB,r)}var u=new aA;az();var aB=new ay;at()})();;function TabControl(b,a){this.selectedTab;this.modelId=b;this.html;this.tabs=[];this.dataType=a;window[this.modelId]=this}TabControl.prototype.selectTab=function(a,b){if(this.tabs[a]){this.selectedTab&&this.selectedTab.deSelect(b);this.selectedTab=this.tabs[a];this.selectedTab.select(b)}this.hfSelectedTab.value=a};TabControl.prototype.tabMouseOver=function(a){this.tabs[a]&&!this.tabs[a].selected&&this.tabs[a].setHTMLStyle("hoveredStyle")};TabControl.prototype.tabMouseOut=function(a){this.tabs[a]&&!this.tabs[a].selected&&this.tabs[a].setHTMLStyle("deSelectedStyle")};TabControl.prototype.addTab=function(a){this.tabs.push(a);return this.tabs.length};TabControl.prototype.deselectTab=function(b,a){b.deselect(a)};TabControl.prototype.render=function(n){var j=this.modelId,d=document.createElement("table");d.width="100%";n.appendChild(d);d.cellPadding="0px";d.cellSpacing="0px";var l=document.createElement("TBODY");d.appendChild(l);var i=document.createElement("tr");l.appendChild(i);for(var a,m=Math.floor(100/(this.tabs.length+1)),b=0;b<this.tabs.length;b++){a=document.createElement("td");a.style.cursor="pointer";a.style.width=m+"%";a.style.verticalAlign="bottom";i.appendChild(a);var c=document.createElement("table");a.appendChild(c);c.style.width="100%";c.cellPadding="0";c.cellSpacing="0";var k=document.createElement("tbody");c.appendChild(k);var f=document.createElement("tr");k.appendChild(f);var h=document.createElement("td"),e=document.createElement("td"),g=document.createElement("td");f.appendChild(h);f.appendChild(e);f.appendChild(g);h.className=this.dataType+"_tabItem_Left";e.className=this.dataType+"_tabItem_Mid";g.className=this.dataType+"_tabItem_Right";e.style.textAlign="center";e.innerHTML=this.tabs[b].label;h.innerHTML="<img src='images/icons/pot.gif' style='width:5px;' />";g.innerHTML="<img src='images/icons/pot.gif' style='width:5px;' />";this.tabs[b].html=a;a.index=b;a.onclick=function(){window[j].selectTab(this.index,300)};a.onmouseover=function(){window[j].tabMouseOver(this.index)};a.onmouseout=function(){window[j].tabMouseOut(this.index)};a.className=this.tabs[b].classNameDefault;this.tabs[b].html=a}a=document.createElement("td");i.appendChild(a);a.innerHTML="&nbsp;";a.className=this.dataType+"_tabItemEmpty"};function TabItem(a,b){this.classNameDefault;this.classNameSelected;this.label=a;this.id=b;this.selected=false;this.html;this.contentHtml;this.footerHtml}TabItem.prototype.addContent=function(a){this.contentHtml=a};TabItem.prototype.addFooter=function(a){this.footerHtml=a};TabItem.prototype.setClassNames=function(b,a){this.classNameDefault=b;this.classNameSelected=a};TabItem.prototype.deSelect=function(a){this.selected=false;a=a?a:0;$("#"+this.contentHtml.id).hide(0);this.setHTMLStyle("deSelectedStyle")};TabItem.prototype.select=function(a){this.selected=true;a=a?a:0;$("#"+this.contentHtml.id).show(0);this.setHTMLStyle("selectedStyle");if(this.footerHtml&&this.footerHtml.length>0)document.getElementById(tdTabItemFooterID).innerHTML=this.footerHtml};TabItem.prototype.setHTMLStyle=function(e){var a="",b="",c="";switch(e){case "selectedStyle":a=this.classNameDefault+"_LeftSelected";b=this.classNameDefault+"_MidSelected";c=this.classNameDefault+"_RightSelected";break;case "deSelectedStyle":a=this.classNameDefault+"_Left";b=this.classNameDefault+"_Mid";c=this.classNameDefault+"_Right";break;case "hoveredStyle":a=this.classNameDefault+"_LeftHover";b=this.classNameDefault+"_MidHover";c=this.classNameDefault+"_RightHover"}var d=this.html.firstChild.firstChild.firstChild.childNodes;d[0].className=a;d[1].className=b;d[2].className=c};function getPosition(a){var b=0,c=0;while(a.offsetParent){b+=a.offsetLeft;c+=a.offsetTop;a=a.offsetParent}b+=a.offsetLeft;c+=a.offsetTop;return {x:b,y:c}}function ArticleTitleRotator(){this.categories;this.init=function(){this.categories=[];if(isBrowserIE()&&navigator.appVersion.indexOf("MSIE 8.0")==-1){var a,b;a=document.getElementById("articleRotator_1_Container");b=parseInt(a.offsetWidth);a.style.position="absolute";a.style.width=b+"px";a=document.getElementById("articleRotator_2_Container");b=parseInt(a.offsetWidth);a.style.position="absolute";a.style.width=b+"px";a=document.getElementById("articleRotator_3_Container");b=parseInt(a.offsetWidth);a.style.position="absolute";a.style.width=b+"px"}};this.init();this.addCategory=function(a){this.categories.push(a)};this.getCategory=function(c){for(var b,a=0;a<this.categories.length;a++)if(c==this.categories[a].id){b=this.categories[a];break}return b};this.pauseRotation=function(b){var a=this.getCategory(b);a&&a.pauseRotation()};this.resumeRotation=function(g,e,f){var a=e?e:event,b=a.relatedTarget?a.relatedTarget:a.toElement?a.toElement:null,c=false;while(b){if(b.parentNode==g){c=true;break}b=b.parentNode}if(!c){var d=this.getCategory(f);d&&d.resumeRotation()}};this.notifyAnimationEnd=function(b,c){var a=this.getCategory(b);a&&a.notify(c)};this.createCategory=function(g,f,e,d,b){this.waitInterval=b;var a={};a.id=g;a.firstRotateDone=false;a.slotHeight=50;a.articleTitles=[];a.title=f;a.navigateUrl=e;a.currentAwaitingAnimationsToEndCount=0;a.waitInterval=b!=undefined?b:2e3;a.registerGUI=function(b){this.gui={};this.gui["clientID"]=b;this.gui["box1"]=document.getElementById("div"+this.gui["clientID"]+"_1");this.gui["box2"]=document.getElementById("div"+this.gui["clientID"]+"_2");if(window.attachEvent){this.gui["box1"].parentNode.onmouseover=function(){window["rotator"].pauseRotation(a.id)};this.gui["box1"].parentNode.onmouseout=function(b){window["rotator"].resumeRotation(this,b,a.id)}}else{this.gui["box1"].parentNode.addEventListener("mouseover",function(){window["rotator"].pauseRotation(a.id)},false);this.gui["box1"].parentNode.addEventListener("mouseout",function(b){window["rotator"].resumeRotation(this,b,a.id)},false)}this.gui["link1"]=document.getElementById("link"+this.gui["clientID"]+"_1");this.gui["link2"]=document.getElementById("link"+this.gui["clientID"]+"_2");this.gui["boxCurrent"]=this.gui["box1"];this.gui["boxNext"]=this.gui["box2"];this.gui["animObjBox1"]=new AnimObjectArticleBanner(this.gui["box1"],0,-this.slotHeight,2,0,this.id,this.waitInterval);this.gui["animObjBox2"]=new AnimObjectArticleBanner(this.gui["box2"],this.slotHeight,0,2,0,this.id,this.waitInterval);this.gui["slotHeight"]=this.slotHeight;this.gui.getCurrentBox=function(){return this.boxCurrent};this.gui.getNextBox=function(){return this.boxNext};this.gui.moveNextArticle=function(){this.boxCurrent=this.boxCurrent==this.box1?this.box2:this.box1;this.boxNext=this.boxCurrent==this.box1?this.box2:this.box1;this.boxNext.style.top=this.slotHeight+"px";if(this.boxCurrent==this.box1){this.animObjBox1.begin=0;this.animObjBox1.finish=-this.slotHeight;this.animObjBox2.begin=this.slotHeight;this.animObjBox2.finish=0}else if(this.boxCurrent==this.box2){this.animObjBox1.begin=this.slotHeight;this.animObjBox1.finish=0;this.animObjBox2.begin=0;this.animObjBox2.finish=-this.slotHeight}return this.currentBox};this.gui.pauseRotation=function(){this["animObjBox1"].pause();this["animObjBox2"].pause()};this.gui.normalizeBoxPositions=function(){this.boxCurrent.style.top=-50+"px";this.boxNext.style.top=0+"px";this["animObjBox1"].time=0;this["animObjBox2"].time=0};this.gui.resumeRotation=function(){this["animObjBox1"].doPause=false;this["animObjBox2"].doPause=false};this.gui.setCurrentArticleText=function(b,c){var a=window.addEventListener!=undefined?this.boxCurrent.childNodes[1].childNodes[1].childNodes[0].childNodes[1].childNodes[1]:this.boxCurrent.firstChild.firstChild.firstChild.firstChild.firstChild;a.innerHTML=this.getTruncatedTitle(b);a.href=c};this.gui.setNextArticleText=function(b,c){var a=window.addEventListener!=undefined?this.boxNext.childNodes[1].childNodes[1].childNodes[0].childNodes[1].childNodes[1]:this.boxNext.firstChild.firstChild.firstChild.firstChild.firstChild,d=b;a.innerHTML=this.getTruncatedTitle(b);a.title=b;a.href=c};this.gui.getTruncatedTitle=function(b){var a=b;if(b.length>c){a=b.substring(0,c);var d=a.replace(/^\s+|\s+$/g,"").substring(0,c).split(" ");d.pop();a=d.join(" ");a+=" ..."}return a}};var c=75;a.toString=function(){return this.title};a.pauseRotation=function(){this.gui.pauseRotation()};a.resumeRotation=function(){this.gui.resumeRotation();this.currentAwaitingAnimationsToEndCount=0;this.firstRotateDone&&this.moveNextArticle();this.startRotate()};a.addArticleTitle=function(){};a.moveNextArticle=function(){this.currentArticleTitleIndex=this.currentArticleTitleIndex<this.articleTitles.length-1?this.currentArticleTitleIndex+1:0;this.nextArticleTitleIndex=this.nextArticleTitleIndex<this.articleTitles.length-1?this.nextArticleTitleIndex+1:0;this.gui.moveNextArticle();this.gui.setNextArticleText(this.articleTitles[this.nextArticleTitleIndex].title,this.articleTitles[this.nextArticleTitleIndex].url)};a.createArticleTitle=function(b,c){var a={};a["title"]=b;a["url"]=c;a["category"]=this;a.toString=function(){return this["title"]};if(this.articleTitles.length==0)this.gui.setCurrentArticleText(b,c);else if(this.articleTitles.length==1){this.nextArticleTitleIndex=1;this.gui.setNextArticleText(b,c)}this.articleTitles.push(a);return a};a.initRotate=function(){this.startRotate()};a.startRotate=function(){if(this.firstRotateDone==false&&!this.gui.animObjBox1.doPause&&!this.gui.animObjBox2.doPause)this.firstRotateDone=true;this.currentAwaitingAnimationsToEndCount=2;!this.gui.animObjBox1.doPause&&this.gui.animObjBox1.beginAnimation();!this.gui.animObjBox2.doPause&&this.gui.animObjBox2.beginAnimation()};a.notify=function(){this.currentAwaitingAnimationsToEndCount--;if(this.currentAwaitingAnimationsToEndCount==0&&!this.gui["animObjBox1"].doPause&&!this.gui["animObjBox2"].doPause){this.moveNextArticle();this.startRotate()}};d&&this.categories.push(a);return a}}function initRotator(){var a=new ArticleTitleRotator;window["rotator"]=a}function AnimObjectArticleBanner(a,f,e,b,g,c,d){this.doPause;this.waitInterval=d;this.category=c;this.varTimeout="timeout_"+a.id;b=60;a.style.position="absolute";this.id="animObj_"+a.getAttribute("id");if(window[this.id]){window.clearTimeout(window["timeout"]);window[this.id]=undefined}this.element=a;this.begin=f;this.finish=e;this.change=this.finish-this.begin;this.duration=b;this.time=g;this.timeoutKey=this.category+"_notifyAnimationEnd";this.pause=function(){this.doPause=true;if(window[this.timeoutKey]==undefined){var a=[];window[this.timeoutKey]=a}while(window[this.timeoutKey].length>0)window.clearTimeout(window[this.timeoutKey].pop())};this.cancelPause=function(){this.doPause=false};this.beginAnimation=function(){if(!this.animationInProgress){this.animationInProgress=true;if(window[this.timeoutKey]==undefined){var a=[];window[this.timeoutKey]=a}while(window[this.timeoutKey].length>0)window.clearTimeout(window[this.timeoutKey].pop());var b=this.id;window[b]=this;this.setNewPosition()}};this.setNewPosition=function(){window.clearTimeout(window[this.varTimeout]);if(this.begin!=this.finish){this.time++;this.change=this.finish-this.begin;this.begin=Math.round(calcPosition(this.time,this.begin,this.change,this.duration));this.element.style.top=this.begin+"px";var a=this.id;window[this.varTimeout]=window.setTimeout("window['"+a+"'].setNewPosition()",30)}else{window[this.varTimeout]=undefined;var c=this.category.id,d=""+this.category;if(!this.doPause){var b=window.setTimeout('window["rotator"].notifyAnimationEnd("'+this.category+'","element")',this.waitInterval);window[this.timeoutKey].push(b);this.time=0}else if(window[this.timeoutKey]!=undefined&&window[this.timeoutKey].length>0)while(window[this.timeoutKey].length>0)window.clearTimeout(window[this.timeoutKey].pop());this.animationInProgress=false}};this.dispose=function(){}}function isBrowserIE(){if(navigator.appVersion.indexOf("MSIE")>-1)return true;return false}function showNotifyBox(b,d,e){var a=document.getElementById("tblNotifyBox");if(a){var c=b!=undefined?getElementPosition(b):null;if(a)a.style.display="block";if(c!=null)var f=parseInt(c[0]),g=parseInt(c[1]);a.style.left=parseInt(b.offsetWidth)+f+"px";a.style.top=g-parseInt(b.offsetHeight)/2+"px";document.getElementById("lblNotifyHeader").innerHTML=d;document.getElementById("lblNotifyText").innerHTML=e}}function multiMenuInitialized(){}function imageOver(c){var a=[],b=c.src;if(b.lastIndexOf("/")>-1)b=b.substring(b.lastIndexOf("/")+1);a=b.split(".");if(a.length>1&&a[0].indexOf("_over")==-1&&a[0].length>0)c.src=c.src.substring(0,c.src.lastIndexOf("/")+1)+""+a[0]+"_over.gif"}function imageOut(c){var b=[],a=c.src;if(a.lastIndexOf("/")>-1)a=a.substring(a.lastIndexOf("/")+1);b=a.split("_over");if(b.length>1&&b[0].length>0)c.src=c.src.substring(0,c.src.lastIndexOf("/")+1)+""+b[0]+".gif"}function openLanguageSelector(){var a=document.getElementById("languageSelectionPanel"),b=arguments[0]!=undefined&&arguments[0].target!=undefined?arguments[0].target:event.srcElement,c=getElementPosition(b);a.style.left=c[0]+"px";a.style.top=b.offsetHeight+5+c[1]+"px";a.style.display="block";if(window.attachEvent){document.documentElement.attachEvent("onclick",function(a){closeLanguageSelector(a)});event.cancelBubble=true}else{arguments[0].stopPropagation();arguments[0].preventDefault()}return false}function closeLanguageSelector(a){a=!a?event:a;var b=document.getElementById("languageSelectionPanel");b.style.display="none";if(a.stopPropagation){a.stopPropagation();a.preventDefault()}else a.cancelBubble=true;return false}function artikelListCol_mouseEvent(b,c,a){if(!a)a=event;classNameStr="";if(c=="simple")switch(a.type){case "mouseover":classNameStr="artikelListSimpleCol_over";break;case "mouseout":classNameStr="artikelListSimpleCol"}else switch(a.type){case "mouseover":classNameStr="artikelListCol_over";break;case "mouseout":classNameStr="artikelListCol"}if(b.childNodes.length>0)if(isBrowserIE())b.childNodes[0].className=classNameStr;else if(b.childNodes[1])b.childNodes[1].className=classNameStr}function noStatusDisplay(){window.status="";return true}function TrimStr(a,c){switch(c){case "left":for(var b=0;b<a.length;b++)if(a.charAt(0)==" ")if(a.length>0){a=a.substring(1,a.length);b-=1}else a="";else break;break;case "right":for(var b=a.length-1;b>-1;b--)if(a.charAt(b)==" ")a=a.substring(0,a.length-1);else break;break;case "all":for(var b=0;b<a.length;b++)if(a.charAt(b)==" "){a=a.replace(/ /,"");b-=1}break;default:for(var b=0;b<a.length;b++)if(a.charAt(0)==" ")if(a.length>0){a=a.substring(1,a.length);b-=1}else a="";else break;for(var b=a.length-1;b>-1;b--)if(a.charAt(b)==" ")a=a.substring(0,a.length-1);else break}return a}function input_focus(a){a.select()}function input_keypress(){if(window.event.keyCode==13){window.event.returnValue=false;return false}}function initImageViewer(c){for(var b,d,a=c;a<c+3;a++){b=document.getElementById("imageSlot"+(a-c));if(imageViewerThumbsArr[a]){d=document.getElementById(imageViewerThumbsArr[a]).cloneNode(true);d.style.display="block";b.innerHTML="";b.appendChild(d)}else b.style.display="none"}}function changeImage(a){if(a>0&&imageIndexor<imageViewerThumbsArr.length-1){imageIndexor++;if(currentImageSlot<2){var c="imageSlot"+currentImageSlot;if(document.getElementById(c).innerHTML!=""){document.getElementById("imageSlot"+currentImageSlot).className="thumbImage";currentImageSlot++;document.getElementById("imageSlot"+currentImageSlot).className="thumbImage_selected"}}else if(currentImageSlot==2){var b=imageIndexor-2;initImageViewer(b)}}else if(a<0&&imageIndexor>0){imageIndexor--;if(currentImageSlot>0){document.getElementById("imageSlot"+currentImageSlot).className="thumbImage";currentImageSlot--;document.getElementById("imageSlot"+currentImageSlot).className="thumbImage_selected"}else initImageViewer(imageIndexor)}switchImages()}function selectImage(b){for(var c=b.getAttribute("id"),a=0;a<imageViewerThumbsArr.length;a++)if(imageViewerThumbsArr[a]==c){imageIndexor=a;break}document.getElementById("imageSlot"+currentImageSlot).className="thumbImage";b.parentNode.className="thumbImage_selected";currentImageSlot=b.parentNode.getAttribute("id").substr(9,1);switchImages()}function switchImages(){var c=document.getElementById("imageTextContainer");c.innerHTML="";var a=document.getElementById("cellImageViewerFullSize"),d=a.firstChild.firstChild;document.getElementById(idPnlImageContent).appendChild(d);d.style.display="none";var b=document.getElementById(imageViewerArr[imageIndexor]);b=b.cloneNode(true);b.style.display="block";if(b.outerHTML){a.firstChild.innerHTML=b.outerHTML;a.firstChild.onmouseover=function(){showMagnifyIcon(a.firstChild.firstChild,a.firstChild.firstChild.id)}}else{a.firstChild.appendChild(b);a.firstChild.onmouseover=function(){showMagnifyIcon(a.firstChild.firstChild,a.firstChild.firstChild.id)}}a.firstChild.href=b.getAttribute("imageSource");c=document.getElementById("imageTextContainer");var f=imageTexts[imageIndexor],g=document.getElementById(f).value;c.innerHTML=g;var e=document.getElementById("lblCurrentImageCount");e.innerHTML=imageIndexor+1;if(imageIndexor>0&&imageIndexor<imageViewerThumbsArr.length-1){document.getElementById("imgNextImage").src="../images/icons/linkRed.gif";document.getElementById("imgPrevImage").src="../images/icons/linkRed_back.gif";document.getElementById("navCellPrev").style.cursor="pointer";document.getElementById("navCellNext").style.cursor="pointer"}else if(imageIndexor==0){document.getElementById("navCellPrev").style.cursor="default";document.getElementById("imgPrevImage").src="../images/icons/linkRed_back_inactive.gif";document.getElementById("imgNextImage").src="../images/icons/linkRed.gif";document.getElementById("navCellNext").style.cursor="pointer"}else{document.getElementById("navCellNext").style.cursor="default";document.getElementById("navCellPrev").style.cursor="pointer";document.getElementById("imgNextImage").src="../images/icons/linkRed_inactive.gif";document.getElementById("imgPrevImage").src="../images/icons/linkRed_back.gif"}}function playAudio(c,b){document.getElementById("videoPlayerContainer")&&document.getElementById("videoPlayerContainer").style.display=="block"&&closePlayer("video");document.getElementById("audioPlayerContainer")&&document.getElementById("audioPlayerContainer").style.display=="block"&&closePlayer("audio");var a=document.getElementById("audioPlayerContainer");if(a){a.style.display="block";document.getElementById("audioFrame").src="../artikel/MediaView.aspx?mediaType="+b+"&URL="+c}}function playVideo(h,g,f,b){document.getElementById("audioPlayerContainer")&&document.getElementById("audioPlayerContainer").style.display=="block"&&closePlayer("audio");document.getElementById("videoPlayerContainer")&&document.getElementById("videoPlayerContainer").style.display=="block"&&closePlayer("video");var a=document.getElementById("videoPlayerContainer");if(a){a.style.display="block";var d=parseInt(f)/parseInt(g)*300,e=300;a.style.display="block";var c=document.getElementById("videoFrame");c.src="../artikel/MediaView.aspx?mediaType="+b+"&URL="+h+"&width="+e+"&height="+d;c.style.height=b=="youtube"?237+"px":250+"px";if(document.getElementById("tblImageViewer"))document.getElementById("tblImageViewer").style.display="none"}}function closePlayer(f){var a=null;switch(f){case "video":var d=document.getElementById("videoFrame");d.src="";a=document.getElementById("videoPlayerContainer");break;case "audio":var e=document.getElementById("audioFrame");e.src="";a=document.getElementById("audioPlayerContainer")}for(var b=0;b<a.childNodes.length;b++)if(a.childNodes[b].tagName=="EMBED")isBrowserIE()&&a.childNodes[b].stop();a.style.display="none";var c;if(c=document.getElementById("tblImageViewer"))c.style.display="block"}function printInFrame(a){var b=document.getElementById("printFrame");b.src=a}function getElementPosition(e){var a=e,b=0,c=0;while(a!=undefined&&a!=null){if(a.offsetLeft!=undefined&&a.offsetLeft!="NaN"&&a.tagName!="DIV"&&a.tagName!="TBODY"&&a.tagName!="TR"&&a.tagName!="SPAN"){b+=a.offsetLeft;c+=a.offsetTop}else if(a.style&&a.style.position=="absolute"){b+=parseInt(a.style.left);c+=parseInt(a.style.top);break}else if(a.tagName=="DIV"){b+=a.offsetLeft;c+=a.offsetTop}a=a.offsetParent}var d=[];d.push(b);d.push(c);return d}function preloadImages(b){if(document.images)for(var a=0;a<b.length;a++){var c=new Image;c.src=b[a]}}function getInternetExplorerVersion(){var a=-1;if(navigator.appName=="Microsoft Internet Explorer"){var c=navigator.userAgent,b=new RegExp("MSIE ([0-9]{1,}[.0-9]{0,})");if(b.exec(c)!=null)a=parseFloat(RegExp.$1)}return a}function supportsPng(){var b=true,a=getInternetExplorerVersion();if(a>-1&&a<7)b=false;return b}function scrollToTop(){window.scrollTo(0,0)}var hiddenControls=[];function hideBuiltInControls(d){var b=document.getElementsByTagName("iframe");if(b&&b.length>0)for(var a=0;a<b.length;a++)if(!d||checkLayersIntersecting(d,b[a])){b[a].style.visibility="hidden";hiddenControls.push(b[a])}var c=document.getElementsByTagName("select");if(c)for(var a=0;a<c.length;a++)if(!d||checkLayersIntersecting(d,c[a])){c[a].style.visibility="hidden";hiddenControls.push(c[a])}}function showHiddenControls(){while(hiddenControls.length>0)hiddenControls.pop().style.visibility="visible"}function SubMenuManager(a){this.rootPath=a;this.hiddenIFrames=[];this.yOffset=0;if(isBrowserIE())this.yOffset=2;this.currentlyOpenSubMenu=null;this.triggerElement=null;this.openSubMenu=function(b,f){this.closeSubMenu();this.triggerElement=b;var a=document.getElementById(f);if(a){var c=getElementPosition(b);if(isBrowserIE()){a.style.left=parseInt(c[0])+parseInt(b.offsetWidth)-2+"px";a.style.top=c[1]}else{a.style.left=parseInt(c[0])+parseInt(b.offsetWidth)+"px";a.style.top=c[1]+"px"}a.style.display="block";this.currentlyOpenSubMenu=a;var d=document.documentElement.clientHeight;if(parseInt(a.style.top)+parseInt(a.offsetHeight)>d+document.documentElement.scrollTop)a.style.top=parseInt(b.offsetHeight)+parseInt(a.style.top)+this.yOffset-parseInt(a.offsetHeight)+"px";if(parseInt(a.offsetWidth)<150){a.style.width="150px";var e=a.firstChild.style?a.firstChild:a.firstChild.nextSibling;e.style.width="150px"}hideBuiltInControls(a)}};this.closeSubMenu=function(){if(this.currentlyOpenSubMenu&&this.currentlyOpenSubMenu.style.display=="block"){this.currentlyOpenSubMenu.style.display="none";showHiddenControls()}}}function checkLayersIntersecting(g,h){var e=getElementPosition(g),f=getElementPosition(h),o=parseInt(g.offsetWidth),m=parseInt(g.offsetHeight),p=parseInt(h.offsetWidth),n=parseInt(h.offsetHeight),k=parseInt(e[0]),i=parseInt(e[0])+o,a=parseInt(e[1]),c=parseInt(e[1])+m,l=parseInt(f[0]),j=parseInt(f[0])+p,b=parseInt(f[1]),d=parseInt(f[1])+n;if((l<i&&l>k||j<i&&j>k)&&(b<c&&b>a||d<c&&d>a||(a<d&&a>b||c<d&&c>b)))return true;else return false}function showSoundSlides(d){var a=document.getElementById("pnlFlashPlayerList"),b=document.getElementById("pnlFlashPlayerView"),c=document.getElementById("pnlFlashPlayerViewFrame");if(a&&b){a.style.display="none";b.style.display="block";c.src=d}}function showSoundSlidesList(){var a=document.getElementById("pnlFlashPlayerList"),b=document.getElementById("pnlFlashPlayerView"),c=document.getElementById("pnlFlashPlayerViewFrame");if(a&&b){c.src="";a.style.display="block";b.style.display="none"}}function clearFields(d){for(var a,b,c=0;c<d.length;c++){a=document.getElementById(d[c]);if(a){b=a.getAttribute("type");switch(b){case "text":a.value="";break;case "textarea":a.value="";break;case "select-one":a.selectedIndex=-1;break;default:alert("Clearing elements of type: "+b+" is not supported")}}}}function getQueryParameters(){var d={},e=document.location.search;if(e.length>0)for(var c=e.substring(1).split("&"),a,b=0;b<c.length;b++){a=c[b].split("=");if(a.length==2)d[a[0].toUpperCase()]=a[1]}return d}function ListModel(a,c,b){this.isClosed=true;this.buttonElement=a;this.srcExpand=c;this.srcCollpase=b;this.arrRowList=[];this.addRow=function(a){this.arrRowList.push(a)};this.expandCollapseList=function(d){switch(d){case "expand":this.isClosed=false;break;case "collapse":this.isClosed=true;break;default:this.isClosed=!this.isClosed}var c="";if(isBrowserIE)c=this.isClosed?"none":"block";else c=this.isClosed?"none":"table-row";this.toggleDisplay(c);var a=this.buttonElement.src.split("/"),b="";if(this.isClosed){a[a.length-1]="list_expand.gif";b=getStringFromDictionary("listevents_VisGruppensIndhold","*")!=undefined?getStringFromDictionary("listevents_VisGruppensIndhold","*"):"Vis gruppens indhold"}else{a[a.length-1]="list_collapse.gif";b=getStringFromDictionary("listevents_SkjulGruppensIndhold","*")!=undefined?getStringFromDictionary("listevents_SkjulGruppensIndhold","*"):"Skjul gruppens indhold"}this.buttonElement.src=a.join("/");this.buttonElement.alt=b};this.toggleDisplay=function(b){for(var a=0;a<this.arrRowList.length;a++)this.arrRowList[a].style.display=b}}var toggleAllListModels=function(b){if(allListModels)for(var a=0;a<allListModels.length;a++)allListModels[a].expandCollapseList(b)},clearImageTexts=function(){if(articleHasImages)for(var b,a=0;a<imageTexts.length;a++){b=document.getElementById(imageTexts[a]);b.value=""}};function Dictionary(){this["DEF"]={};this.cultures=[];this.cultures.push(this["DEF"])}Dictionary.prototype.getWord=function(c,a){var b="";if(c!=undefined&&a!=undefined)if(this[a]&&this[a][c])b=this[a][c];else b="";return b};Dictionary.prototype.addWord=function(c,b,a){if(c&&b&&a){if(a&&!this[a])this[a]={};this[a][c]=b}};function addStringToDictionary(d,b,a){a=a=="*"?"DEF":a;var c=null;if(!window["dictionary"])window["dictionary"]=new Dictionary;c=window["dictionary"];if(d&&b){a=a!=undefined?a:"DEF";c.addWord(d,b,a)}}function getStringFromDictionary(c,a){a=a=="*"?"DEF":a;var b="";if(window["dictionary"]){var b=window["dictionary"].getWord(c,a);b=b!=false?b:c}return b}function deactivateLinks(a){if(a.tagName=="A"){var c=a.parentNode,d=a.innerHTML;c.removeChild(a);c.innerHTML+="<b>"+d+"</b>"}else if(a.hasChildNodes())for(var b=0;b<a.childNodes.length;b++)if(a.childNodes[b].tagName)a.childNodes[b].hasChildNodes()&&deactivateLinks(a.childNodes[b])}var calcPosition=function(a,b,c,d){if((a/=d/2)<1)return c/2*a*a+b;else return -c/2*(--a*(a-2)-1)+b};Calendar=function(c,e,d,f){this.activeDiv=null;this.currentDateEl=null;this.getDateStatus=null;this.getDateToolTip=null;this.getDateText=null;this.timeout=null;this.onSelected=d||null;this.onClose=f||null;this.dragging=false;this.hidden=false;this.minYear=1970;this.maxYear=2050;this.dateFormat=Calendar._TT["DEF_DATE_FORMAT"];this.ttDateFormat=Calendar._TT["TT_DATE_FORMAT"];this.isPopup=true;this.weekNumbers=true;this.firstDayOfWeek=typeof c=="number"?c:Calendar._FD;this.showsOtherMonths=false;this.dateStr=e;this.ar_days=null;this.showsTime=false;this.time24=true;this.yearStep=2;this.hiliteToday=true;this.multiple=null;this.table=null;this.element=null;this.tbody=null;this.firstdayname=null;this.monthsCombo=null;this.yearsCombo=null;this.hilitedMonth=null;this.activeMonth=null;this.hilitedYear=null;this.activeYear=null;this.dateClicked=false;if(typeof Calendar._SDN=="undefined"){if(typeof Calendar._SDN_len=="undefined")Calendar._SDN_len=3;for(var b=[],a=8;a>0;)b[--a]=Calendar._DN[a].substr(0,Calendar._SDN_len);Calendar._SDN=b;if(typeof Calendar._SMN_len=="undefined")Calendar._SMN_len=3;b=[];for(var a=12;a>0;)b[--a]=Calendar._MN[a].substr(0,Calendar._SMN_len);Calendar._SMN=b}};Calendar._C=null;Calendar.is_ie=/msie/i.test(navigator.userAgent)&&!/opera/i.test(navigator.userAgent);Calendar.is_ie5=Calendar.is_ie&&/msie 5\.0/i.test(navigator.userAgent);Calendar.is_opera=/opera/i.test(navigator.userAgent);Calendar.is_khtml=/Konqueror|Safari|KHTML/i.test(navigator.userAgent);Calendar.getAbsolutePos=function(a){var e=0,f=0,c=/^div$/i.test(a.tagName);if(c&&a.scrollLeft)e=a.scrollLeft;if(c&&a.scrollTop)f=a.scrollTop;var b={x:a.offsetLeft-e,y:a.offsetTop-f};if(a.offsetParent){var d=this.getAbsolutePos(a.offsetParent);b.x+=d.x;b.y+=d.y}return b};Calendar.isRelated=function(d,b){var a=b.relatedTarget;if(!a){var c=b.type;if(c=="mouseover")a=b.fromElement;else if(c=="mouseout")a=b.toElement}while(a){if(a==d)return true;a=a.parentNode}return false};Calendar.removeClass=function(a,e){if(!(a&&a.className))return;for(var b=a.className.split(" "),c=[],d=b.length;d>0;)if(b[--d]!=e)c[c.length]=b[d];a.className=c.join(" ")};Calendar.addClass=function(b,a){Calendar.removeClass(b,a);b.className+=" "+a};Calendar.getElement=function(b){var a=Calendar.is_ie?window.event.srcElement:b.currentTarget;while(a.nodeType!=1||/^div$/i.test(a.tagName))a=a.parentNode;return a};Calendar.getTargetElement=function(b){var a=Calendar.is_ie?window.event.srcElement:b.target;while(a.nodeType!=1)a=a.parentNode;return a};Calendar.stopEvent=function(a){a||(a=window.event);if(Calendar.is_ie){a.cancelBubble=true;a.returnValue=false}else{a.preventDefault();a.stopPropagation()}return false};Calendar.addEvent=function(a,b,c){if(a.attachEvent)a.attachEvent("on"+b,c);else if(a.addEventListener)a.addEventListener(b,c,true);else a["on"+b]=c};Calendar.removeEvent=function(a,b,c){if(a.detachEvent)a.detachEvent("on"+b,c);else if(a.removeEventListener)a.removeEventListener(b,c,true);else a["on"+b]=null};Calendar.createElement=function(c,b){var a=null;if(document.createElementNS)a=document.createElementNS("http://www.w3.org/1999/xhtml",c);else a=document.createElement(c);typeof b!="undefined"&&b.appendChild(a);return a};Calendar._add_evs=function(el){with(Calendar){addEvent(el,"mouseover",dayMouseOver);addEvent(el,"mousedown",dayMouseDown);addEvent(el,"mouseout",dayMouseOut);if(is_ie){addEvent(el,"dblclick",dayMouseDblClick);el.setAttribute("unselectable",true)}}};Calendar.findMonth=function(a){if(typeof a.month!="undefined")return a;else if(typeof a.parentNode.month!="undefined")return a.parentNode;return null};Calendar.findYear=function(a){if(typeof a.year!="undefined")return a;else if(typeof a.parentNode.year!="undefined")return a.parentNode;return null};Calendar.showMonthsCombo=function(){var a=Calendar._C;if(!a)return false;var a=a,b=a.activeDiv,f=a.monthsCombo;a.hilitedMonth&&Calendar.removeClass(a.hilitedMonth,"hilite");a.activeMonth&&Calendar.removeClass(a.activeMonth,"active");var e=a.monthsCombo.getElementsByTagName("div")[a.date.getMonth()];Calendar.addClass(e,"active");a.activeMonth=e;var c=f.style;c.display="block";if(b.navtype<0)c.left=b.offsetLeft+"px";else{var d=f.offsetWidth;if(typeof d=="undefined")d=50;c.left=b.offsetLeft+b.offsetWidth-d+"px"}c.top=b.offsetTop+b.offsetHeight+"px"};Calendar.showYearsCombo=function(i){var a=Calendar._C;if(!a)return false;var a=a,b=a.activeDiv,g=a.yearsCombo;a.hilitedYear&&Calendar.removeClass(a.hilitedYear,"hilite");a.activeYear&&Calendar.removeClass(a.activeYear,"active");a.activeYear=null;for(var d=a.date.getFullYear()+(i?1:-1),c=g.firstChild,h=false,j=12;j>0;--j){if(d>=a.minYear&&d<=a.maxYear){c.innerHTML=d;c.year=d;c.style.display="block";h=true}else c.style.display="none";c=c.nextSibling;d+=i?a.yearStep:-a.yearStep}if(h){var e=g.style;e.display="block";if(b.navtype<0)e.left=b.offsetLeft+"px";else{var f=g.offsetWidth;if(typeof f=="undefined")f=50;e.left=b.offsetLeft+b.offsetWidth-f+"px"}e.top=b.offsetTop+b.offsetHeight+"px"}};Calendar.tableMouseUp=function(ev){var cal=Calendar._C;if(!cal)return false;cal.timeout&&clearTimeout(cal.timeout);var el=cal.activeDiv;if(!el)return false;var target=Calendar.getTargetElement(ev);ev||(ev=window.event);Calendar.removeClass(el,"active");(target==el||target.parentNode==el)&&Calendar.cellClick(el,ev);var mon=Calendar.findMonth(target),date=null;if(mon){date=new Date(cal.date);if(mon.month!=date.getMonth()){date.setMonth(mon.month);cal.setDate(date);cal.dateClicked=false;cal.callHandler()}}else{var year=Calendar.findYear(target);if(year){date=new Date(cal.date);if(year.year!=date.getFullYear()){date.setFullYear(year.year);cal.setDate(date);cal.dateClicked=false;cal.callHandler()}}}with(Calendar){removeEvent(document,"mouseup",tableMouseUp);removeEvent(document,"mouseover",tableMouseOver);removeEvent(document,"mousemove",tableMouseOver);cal._hideCombos();_C=null;return stopEvent(ev)}};Calendar.tableMouseOver=function(g){var a=Calendar._C;if(!a)return;var b=a.activeDiv,e=Calendar.getTargetElement(g);if(e==b||e.parentNode==b){Calendar.addClass(b,"hilite active");Calendar.addClass(b.parentNode,"rowhilite")}else{(typeof b.navtype=="undefined"||b.navtype!=50&&(b.navtype==0||Math.abs(b.navtype)>2))&&Calendar.removeClass(b,"active");Calendar.removeClass(b,"hilite");Calendar.removeClass(b.parentNode,"rowhilite")}g||(g=window.event);if(b.navtype==50&&e!=b){var j=Calendar.getAbsolutePos(b),m=b.offsetWidth,k=g.clientX,f,l=true;if(k>j.x+m){f=k-j.x-m;l=false}else f=j.x-k;if(f<0)f=0;for(var d=b._range,n=b._current,p=Math.floor(f/10)%d.length,c=d.length;--c>=0;)if(d[c]==n)break;while(p-->0)if(l){if(--c<0)c=d.length-1}else if(++c>=d.length)c=0;var o=d[c];b.innerHTML=o;a.onUpdateTime()}var i=Calendar.findMonth(e);if(i)if(i.month!=a.date.getMonth()){a.hilitedMonth&&Calendar.removeClass(a.hilitedMonth,"hilite");Calendar.addClass(i,"hilite");a.hilitedMonth=i}else a.hilitedMonth&&Calendar.removeClass(a.hilitedMonth,"hilite");else{a.hilitedMonth&&Calendar.removeClass(a.hilitedMonth,"hilite");var h=Calendar.findYear(e);if(h)if(h.year!=a.date.getFullYear()){a.hilitedYear&&Calendar.removeClass(a.hilitedYear,"hilite");Calendar.addClass(h,"hilite");a.hilitedYear=h}else a.hilitedYear&&Calendar.removeClass(a.hilitedYear,"hilite");else a.hilitedYear&&Calendar.removeClass(a.hilitedYear,"hilite")}return Calendar.stopEvent(g)};Calendar.tableMouseDown=function(a){if(Calendar.getTargetElement(a)==Calendar.getElement(a))return Calendar.stopEvent(a)};Calendar.calDragIt=function(d){var a=Calendar._C;if(!(a&&a.dragging))return false;var b,c;if(Calendar.is_ie){c=window.event.clientY+document.body.scrollTop;b=window.event.clientX+document.body.scrollLeft}else{b=d.pageX;c=d.pageY}a.hideShowCovered();var e=a.element.style;e.left=b-a.xOffs+"px";e.top=c-a.yOffs+"px";return Calendar.stopEvent(d)};Calendar.calDragEnd=function(ev){var cal=Calendar._C;if(!cal)return false;cal.dragging=false;with(Calendar){removeEvent(document,"mousemove",calDragIt);removeEvent(document,"mouseup",calDragEnd);tableMouseUp(ev)}cal.hideShowCovered()};Calendar.dayMouseDown=function(ev){var el=Calendar.getElement(ev);if(el.disabled)return false;var cal=el.calendar;cal.activeDiv=el;Calendar._C=cal;if(el.navtype!=300)with(Calendar){if(el.navtype==50){el._current=el.innerHTML;addEvent(document,"mousemove",tableMouseOver)}else addEvent(document,Calendar.is_ie5?"mousemove":"mouseover",tableMouseOver);addClass(el,"hilite active");addEvent(document,"mouseup",tableMouseUp)}else cal.isPopup&&cal._dragStart(ev);if(el.navtype==-1||el.navtype==1){cal.timeout&&clearTimeout(cal.timeout);cal.timeout=setTimeout("Calendar.showMonthsCombo()",250)}else if(el.navtype==-2||el.navtype==2){cal.timeout&&clearTimeout(cal.timeout);cal.timeout=setTimeout(el.navtype>0?"Calendar.showYearsCombo(true)":"Calendar.showYearsCombo(false)",250)}else cal.timeout=null;return Calendar.stopEvent(ev)};Calendar.dayMouseDblClick=function(a){Calendar.cellClick(Calendar.getElement(a),a||window.event);Calendar.is_ie&&document.selection.empty()};Calendar.dayMouseOver=function(b){var a=Calendar.getElement(b);if(Calendar.isRelated(a,b)||Calendar._C||a.disabled)return false;if(a.ttip){if(a.ttip.substr(0,1)=="_")a.ttip=a.caldate.print(a.calendar.ttDateFormat)+a.ttip.substr(1);a.calendar.tooltips.innerHTML=a.ttip}if(a.navtype!=300){Calendar.addClass(a,"hilite");a.caldate&&Calendar.addClass(a.parentNode,"rowhilite")}return Calendar.stopEvent(b)};Calendar.dayMouseOut=function(ev){with(Calendar){var el=getElement(ev);if(isRelated(el,ev)||_C||el.disabled)return false;removeClass(el,"hilite");el.caldate&&removeClass(el.parentNode,"rowhilite");if(el.calendar)el.calendar.tooltips.innerHTML=_TT["SEL_DATE"];return stopEvent(ev)}};Calendar.cellClick=function(c,l){var a=c.calendar,h=false,i=false,b=null;if(typeof c.navtype=="undefined"){if(a.currentDateEl){Calendar.removeClass(a.currentDateEl,"selected");Calendar.addClass(c,"selected");h=a.currentDateEl==c;if(!h)a.currentDateEl=c}a.date.setDateOnly(c.caldate);b=a.date;var m=!(a.dateClicked=!c.otherMonth);if(!m&&!a.currentDateEl)a._toggleMultipleDate(new Date(b));else i=!c.disabled;m&&a._init(a.firstDayOfWeek,b)}else{if(c.navtype==200){Calendar.removeClass(c,"hilite");a.callCloseHandler();return}b=new Date(a.date);c.navtype==0&&b.setDateOnly(new Date);a.dateClicked=false;var d=b.getFullYear(),k=b.getMonth();function g(c){var d=b.getDate(),a=b.getMonthDays(c);d>a&&b.setDate(a);b.setMonth(c)}switch(c.navtype){case 400:Calendar.removeClass(c,"hilite");var j=Calendar._TT["ABOUT"];if(typeof j!="undefined")j+=a.showsTime?Calendar._TT["ABOUT_TIME"]:"";else j='Help and about box text is not translated into this language.\nIf you know this language and you feel generous please update\nthe corresponding file in "lang" subdir to match calendar-en.js\nand send it back to <mihai_bazon@yahoo.com> to get it into the distribution  ;-)\n\nThank you!\nhttp://dynarch.com/mishoo/calendar.epl\n';alert(j);return;case -2:d>a.minYear&&b.setFullYear(d-1);break;case -1:if(k>0)g(k-1);else if(d-->a.minYear){b.setFullYear(d);g(11)}break;case 1:if(k<11)g(k+1);else if(d<a.maxYear){b.setFullYear(d+1);g(0)}break;case 2:d<a.maxYear&&b.setFullYear(d+1);break;case 100:a.setFirstDayOfWeek(c.fdow);return;case 50:for(var f=c._range,n=c.innerHTML,e=f.length;--e>=0;)if(f[e]==n)break;if(l&&l.shiftKey){if(--e<0)e=f.length-1}else if(++e>=f.length)e=0;var o=f[e];c.innerHTML=o;a.onUpdateTime();return;case 0:if(typeof a.getDateStatus=="function"&&a.getDateStatus(b,b.getFullYear(),b.getMonth(),b.getDate()))return false}if(!b.equalsTo(a.date)){a.setDate(b);i=true}else if(c.navtype==0)i=h=true}if(i)l&&a.callHandler();if(h){Calendar.removeClass(c,"hilite");l&&a.callCloseHandler()}};Calendar.prototype.create=function(m){var j=null;if(!m){j=document.getElementsByTagName("body")[0];this.isPopup=true}else{j=m;this.isPopup=false}this.date=this.dateStr?new Date(this.dateStr):new Date;var e=Calendar.createElement("table");this.table=e;e.cellSpacing=0;e.cellPadding=0;e.calendar=this;Calendar.addEvent(e,"mousedown",Calendar.tableMouseDown);var d=Calendar.createElement("div");this.element=d;d.className="calendar";if(this.isPopup){d.style.position="absolute";d.style.display="none"}d.appendChild(e);var l=Calendar.createElement("thead",e),a=null,b=null,g=this,f=function(d,e,c){a=Calendar.createElement("td",b);a.colSpan=e;a.className="button";if(c!=0&&Math.abs(c)<=2)a.className+=" nav";Calendar._add_evs(a);a.calendar=g;a.navtype=c;a.innerHTML="<div unselectable='on'>"+d+"</div>";return a};b=Calendar.createElement("tr",l);var i=6;this.isPopup&&--i;this.weekNumbers&&++i;f("?",1,400).ttip=Calendar._TT["INFO"];this.title=f("",i,300);this.title.className="title";if(this.isPopup){this.title.ttip=Calendar._TT["DRAG_TO_MOVE"];this.title.style.cursor="move";f("&#x00d7;",1,200).ttip=Calendar._TT["CLOSE"]}b=Calendar.createElement("tr",l);b.className="headrow";this._nav_py=f("&#x00ab;",1,-2);this._nav_py.ttip=Calendar._TT["PREV_YEAR"];this._nav_pm=f("&#x2039;",1,-1);this._nav_pm.ttip=Calendar._TT["PREV_MONTH"];this._nav_now=f(Calendar._TT["TODAY"],this.weekNumbers?4:3,0);this._nav_now.ttip=Calendar._TT["GO_TODAY"];this._nav_nm=f("&#x203a;",1,1);this._nav_nm.ttip=Calendar._TT["NEXT_MONTH"];this._nav_ny=f("&#x00bb;",1,2);this._nav_ny.ttip=Calendar._TT["NEXT_YEAR"];b=Calendar.createElement("tr",l);b.className="daynames";if(this.weekNumbers){a=Calendar.createElement("td",b);a.className="name wn";a.innerHTML=Calendar._TT["WK"]}for(var c=7;c>0;--c){a=Calendar.createElement("td",b);if(!c){a.navtype=100;a.calendar=this;Calendar._add_evs(a)}}this.firstdayname=this.weekNumbers?b.firstChild.nextSibling:b.firstChild;this._displayWeekdays();var k=Calendar.createElement("tbody",e);this.tbody=k;for(c=6;c>0;--c){b=Calendar.createElement("tr",k);if(this.weekNumbers)a=Calendar.createElement("td",b);for(var o=7;o>0;--o){a=Calendar.createElement("td",b);a.calendar=this;Calendar._add_evs(a)}}if(this.showsTime){b=Calendar.createElement("tr",k);b.className="time";a=Calendar.createElement("td",b);a.className="time";a.colSpan=2;a.innerHTML=Calendar._TT["TIME"]||"&nbsp;";a=Calendar.createElement("td",b);a.className="time";a.colSpan=this.weekNumbers?4:3;(function(){function e(h,i,d,f){var b=Calendar.createElement("span",a);b.className=h;b.innerHTML=i;b.calendar=g;b.ttip=Calendar._TT["TIME_PART"];b.navtype=50;b._range=[];if(typeof d!="number")b._range=d;else for(var c=d;c<=f;++c){var e;if(c<10&&f>=10)e="0"+c;else e=""+c;b._range[b._range.length]=e}Calendar._add_evs(b);return b}var f=g.date.getHours(),l=g.date.getMinutes(),c=!g.time24,i=f>12;if(c&&i)f-=12;var j=e("hour",f,c?1:0,c?12:23),h=Calendar.createElement("span",a);h.innerHTML=":";h.className="colon";var k=e("minute",l,0,59),d=null;a=Calendar.createElement("td",b);a.className="time";a.colSpan=2;if(c)d=e("ampm",i?"pm":"am",["am","pm"]);else a.innerHTML="&nbsp;";g.onSetTime=function(){var e,a=this.date.getHours(),b=this.date.getMinutes();if(c){e=a>=12;if(e)a-=12;if(a==0)a=12;d.innerHTML=e?"pm":"am"}j.innerHTML=a<10?"0"+a:a;k.innerHTML=b<10?"0"+b:b};g.onUpdateTime=function(){var a=this.date,b=parseInt(j.innerHTML,10);if(c)if(/pm/i.test(d.innerHTML)&&b<12)b+=12;else if(/am/i.test(d.innerHTML)&&b==12)b=0;var e=a.getDate(),f=a.getMonth(),g=a.getFullYear();a.setHours(b);a.setMinutes(parseInt(k.innerHTML,10));a.setFullYear(g);a.setMonth(f);a.setDate(e);this.dateClicked=false;this.callHandler()}})()}else this.onSetTime=this.onUpdateTime=function(){};var p=Calendar.createElement("tfoot",e);b=Calendar.createElement("tr",p);b.className="footrow";a=f(Calendar._TT["SEL_DATE"],this.weekNumbers?8:7,300);a.className="ttip";if(this.isPopup){a.ttip=Calendar._TT["DRAG_TO_MOVE"];a.style.cursor="move"}this.tooltips=a;d=Calendar.createElement("div",this.element);this.monthsCombo=d;d.className="combo";for(c=0;c<Calendar._MN.length;++c){var h=Calendar.createElement("div");h.className=Calendar.is_ie?"label-IEfix":"label";h.month=c;h.innerHTML=Calendar._SMN[c];d.appendChild(h)}d=Calendar.createElement("div",this.element);this.yearsCombo=d;d.className="combo";for(c=12;c>0;--c){var n=Calendar.createElement("div");n.className=Calendar.is_ie?"label-IEfix":"label";d.appendChild(n)}this._init(this.firstDayOfWeek,this.date);j.appendChild(this.element)};Calendar._keyEvent=function(g){var a=window._dynarch_popupCalendar;if(!a||a.multiple)return false;Calendar.is_ie&&(g=window.event);var f=Calendar.is_ie||g.type=="keypress",c=g.keyCode;if(g.ctrlKey)switch(c){case 37:f&&Calendar.cellClick(a._nav_pm);break;case 38:f&&Calendar.cellClick(a._nav_py);break;case 39:f&&Calendar.cellClick(a._nav_nm);break;case 40:f&&Calendar.cellClick(a._nav_ny);break;default:return false}else switch(c){case 32:Calendar.cellClick(a._nav_now);break;case 27:f&&a.callCloseHandler();break;case 37:case 38:case 39:case 40:if(f){var l,b,e,d,m,i;l=c==37||c==38;i=c==37||c==39?1:7;function h(){m=a.currentDateEl;var c=m.pos;b=c&15;e=c>>4;d=a.ar_days[e][b]}h();function k(){var b=new Date(a.date);b.setDate(b.getDate()-i);a.setDate(b)}function j(){var b=new Date(a.date);b.setDate(b.getDate()+i);a.setDate(b)}while(1){switch(c){case 37:if(--b>=0)d=a.ar_days[e][b];else{b=6;c=38;continue}break;case 38:if(--e>=0)d=a.ar_days[e][b];else{k();h()}break;case 39:if(++b<7)d=a.ar_days[e][b];else{b=0;c=40;continue}break;case 40:if(++e<a.ar_days.length)d=a.ar_days[e][b];else{j();h()}}break}if(d)if(!d.disabled)Calendar.cellClick(d);else if(l)k();else j()}break;case 13:f&&Calendar.cellClick(a.currentDateEl,g);break;default:return false}return Calendar.stopEvent(g)};Calendar.prototype._init=function(q,b){var j=new Date,x=j.getFullYear(),w=j.getMonth(),v=j.getDate();this.table.style.visibility="hidden";var c=b.getFullYear();if(c<this.minYear){c=this.minYear;b.setFullYear(c)}else if(c>this.maxYear){c=this.maxYear;b.setFullYear(c)}this.firstDayOfWeek=q;this.date=new Date(b);var e=b.getMonth(),t=b.getDate(),y=b.getMonthDays();b.setDate(1);var k=(b.getDay()-this.firstDayOfWeek)%7;if(k<0)k+=7;b.setDate(-k);b.setDate(b.getDate()+1);for(var f=this.tbody.firstChild,z=Calendar._SMN[e],r=this.ar_days=[],o=Calendar._TT["WEEKEND"],p=this.multiple?(this.datesCells={}):null,g=0;g<6;++g,f=f.nextSibling){var a=f.firstChild;if(this.weekNumbers){a.className="day wn";a.innerHTML=b.getWeekNumber();a=a.nextSibling}f.className="daysrow";for(var m=false,d,s=r[g]=[],h=0;h<7;++h,a=a.nextSibling,b.setDate(d+1)){d=b.getDate();var u=b.getDay();a.className="day";a.pos=g<<4|h;s[h]=a;var l=b.getMonth()==e;if(!l)if(this.showsOtherMonths){a.className+=" othermonth";a.otherMonth=true}else{a.className="emptycell";a.innerHTML="&nbsp;";a.disabled=true;continue}else{a.otherMonth=false;m=true}a.disabled=false;a.innerHTML=this.getDateText?this.getDateText(b,d):d;if(p)p[b.print("%Y%m%d")]=a;if(this.getDateStatus){var i=this.getDateStatus(b,c,e,d);if(this.getDateToolTip){var n=this.getDateToolTip(b,c,e,d);if(n)a.title=n}if(i===true){a.className+=" disabled";a.disabled=true}else{if(/disabled/i.test(i))a.disabled=true;a.className+=" "+i}}if(!a.disabled){a.caldate=new Date(b);a.ttip="_";if(!this.multiple&&l&&d==t&&this.hiliteToday){a.className+=" selected";this.currentDateEl=a}if(b.getFullYear()==x&&b.getMonth()==w&&d==v){a.className+=" today";a.ttip+=Calendar._TT["PART_TODAY"]}if(o&&o.indexOf(u.toString())!=-1)a.className+=a.otherMonth?" oweekend":" weekend"}}if(!(m||this.showsOtherMonths))f.className="emptyrow"}this.title.innerHTML=Calendar._MN[e]+", "+c;this.onSetTime();this.table.style.visibility="visible";this._initMultipleDates()};Calendar.prototype._initMultipleDates=function(){if(this.multiple)for(var b in this.multiple){var a=this.datesCells[b],c=this.multiple[b];if(!c)continue;if(a)a.className+=" selected"}};Calendar.prototype._toggleMultipleDate=function(c){if(this.multiple){var a=c.print("%Y%m%d"),b=this.datesCells[a];if(b){var d=this.multiple[a];if(!d){Calendar.addClass(b,"selected");this.multiple[a]=c}else{Calendar.removeClass(b,"selected");delete this.multiple[a]}}}};Calendar.prototype.setDateToolTipHandler=function(a){this.getDateToolTip=a};Calendar.prototype.setDate=function(a){!a.equalsTo(this.date)&&this._init(this.firstDayOfWeek,a)};Calendar.prototype.refresh=function(){this._init(this.firstDayOfWeek,this.date)};Calendar.prototype.setFirstDayOfWeek=function(a){this._init(a,this.date);this._displayWeekdays()};Calendar.prototype.setDateStatusHandler=Calendar.prototype.setDisabledHandler=function(a){this.getDateStatus=a};Calendar.prototype.setRange=function(a,b){this.minYear=a;this.maxYear=b};Calendar.prototype.callHandler=function(){this.onSelected&&this.onSelected(this,this.date.print(this.dateFormat))};Calendar.prototype.callCloseHandler=function(){this.onClose&&this.onClose(this);this.hideShowCovered()};Calendar.prototype.destroy=function(){var a=this.element.parentNode;a.removeChild(this.element);Calendar._C=null;window._dynarch_popupCalendar=null};Calendar.prototype.reparent=function(b){var a=this.element;a.parentNode.removeChild(a);b.appendChild(a)};Calendar._checkCalendar=function(b){var c=window._dynarch_popupCalendar;if(!c)return false;for(var a=Calendar.is_ie?Calendar.getElement(b):Calendar.getTargetElement(b);a!=null&&a!=c.element;a=a.parentNode);if(a==null){window._dynarch_popupCalendar.callCloseHandler();return Calendar.stopEvent(b)}};Calendar.prototype.show=function(){for(var c=this.table.getElementsByTagName("tr"),e=c.length;e>0;){var d=c[--e];Calendar.removeClass(d,"rowhilite");for(var a=d.getElementsByTagName("td"),f=a.length;f>0;){var b=a[--f];Calendar.removeClass(b,"hilite");Calendar.removeClass(b,"active")}}this.element.style.display="block";this.hidden=false;if(this.isPopup){window._dynarch_popupCalendar=this;Calendar.addEvent(document,"keydown",Calendar._keyEvent);Calendar.addEvent(document,"keypress",Calendar._keyEvent);Calendar.addEvent(document,"mousedown",Calendar._checkCalendar)}this.hideShowCovered()};Calendar.prototype.hide=function(){if(this.isPopup){Calendar.removeEvent(document,"keydown",Calendar._keyEvent);Calendar.removeEvent(document,"keypress",Calendar._keyEvent);Calendar.removeEvent(document,"mousedown",Calendar._checkCalendar)}this.element.style.display="none";this.hidden=true;this.hideShowCovered()};Calendar.prototype.showAt=function(b,c){var a=this.element.style;a.left=b+"px";a.top=c+"px";this.show()};Calendar.prototype.showAtElement=function(b,c){var d=this,a=Calendar.getAbsolutePos(b);if(!c||typeof c!="string"){this.showAt(a.x,a.y+b.offsetHeight);return true}function e(a){if(a.x<0)a.x=0;if(a.y<0)a.y=0;var e=document.createElement("div"),d=e.style;d.position="absolute";d.right=d.bottom=d.width=d.height="0px";document.body.appendChild(e);var b=Calendar.getAbsolutePos(e);document.body.removeChild(e);if(Calendar.is_ie){b.y+=document.body.scrollTop;b.x+=document.body.scrollLeft}else{b.y+=window.scrollY;b.x+=window.scrollX}var c=a.x+a.width-b.x;if(c>0)a.x-=c;c=a.y+a.height-b.y;if(c>0)a.y-=c}this.element.style.display="block";Calendar.continuation_for_the_fucking_khtml_browser=function(){var g=d.element.offsetWidth,f=d.element.offsetHeight;d.element.style.display="none";var i=c.substr(0,1),h="l";if(c.length>1)h=c.substr(1,1);switch(i){case "T":a.y-=f;break;case "B":a.y+=b.offsetHeight;break;case "C":a.y+=(b.offsetHeight-f)/2;break;case "t":a.y+=b.offsetHeight-f}switch(h){case "L":a.x-=g;break;case "R":a.x+=b.offsetWidth;break;case "C":a.x+=(b.offsetWidth-g)/2;break;case "l":a.x+=b.offsetWidth-g}a.width=g;a.height=f+40;d.monthsCombo.style.display="none";e(a);d.showAt(a.x,a.y)};if(Calendar.is_khtml)setTimeout("Calendar.continuation_for_the_fucking_khtml_browser()",10);else Calendar.continuation_for_the_fucking_khtml_browser()};Calendar.prototype.setDateFormat=function(a){this.dateFormat=a};Calendar.prototype.setTtDateFormat=function(a){this.ttDateFormat=a};Calendar.prototype.parseDate=function(b,a){if(!a)a=this.dateFormat;this.setDate(Date.parseDate(b,a))};Calendar.prototype.hideShowCovered=function(){if(!Calendar.is_ie&&!Calendar.is_opera)return;function d(b){var a=b.style.visibility;if(!a)if(document.defaultView&&typeof document.defaultView.getComputedStyle=="function")if(!Calendar.is_khtml)a=document.defaultView.getComputedStyle(b,"").getPropertyValue("visibility");else a="";else if(b.currentStyle)a=b.currentStyle.visibility;else a="";return a}for(var e=["applet","iframe","select"],c=this.element,b=Calendar.getAbsolutePos(c),h=b.x,o=c.offsetWidth+h,i=b.y,p=c.offsetHeight+i,l=e.length;l>0;)for(var j=document.getElementsByTagName(e[--l]),a=null,k=j.length;k>0;){a=j[--k];b=Calendar.getAbsolutePos(a);var f=b.x,m=a.offsetWidth+f,g=b.y,n=a.offsetHeight+g;if(this.hidden||f>o||m<h||g>p||n<i){if(!a.__msh_save_visibility)a.__msh_save_visibility=d(a);a.style.visibility=a.__msh_save_visibility}else{if(!a.__msh_save_visibility)a.__msh_save_visibility=d(a);a.style.visibility="hidden"}}};Calendar.prototype._displayWeekdays=function(){for(var e=this.firstDayOfWeek,a=this.firstdayname,d=Calendar._TT["WEEKEND"],b=0;b<7;++b){a.className="day name";var c=(b+e)%7;if(b){a.ttip=Calendar._TT["DAY_FIRST"].replace("%s",Calendar._DN[c]);a.navtype=100;a.calendar=this;a.fdow=c;Calendar._add_evs(a)}d&&d.indexOf(c.toString())!=-1&&Calendar.addClass(a,"weekend");a.innerHTML=Calendar._SDN[(b+e)%7];a=a.nextSibling}};Calendar.prototype._hideCombos=function(){this.monthsCombo.style.display="none";this.yearsCombo.style.display="none"};Calendar.prototype._dragStart=function(ev){if(this.dragging)return;this.dragging=true;var posX,posY;if(Calendar.is_ie){posY=window.event.clientY+document.body.scrollTop;posX=window.event.clientX+document.body.scrollLeft}else{posY=ev.clientY+window.scrollY;posX=ev.clientX+window.scrollX}var st=this.element.style;this.xOffs=posX-parseInt(st.left);this.yOffs=posY-parseInt(st.top);with(Calendar){addEvent(document,"mousemove",calDragIt);addEvent(document,"mouseup",calDragEnd)}};Date._MD=[31,28,31,30,31,30,31,31,30,31,30,31];Date.SECOND=1e3;Date.MINUTE=60*Date.SECOND;Date.HOUR=60*Date.MINUTE;Date.DAY=24*Date.HOUR;Date.WEEK=7*Date.DAY;Date.parseDate=function(l,k){for(var h=new Date,c=0,d=-1,e=0,b=l.split(/\W+/),m=k.match(/%./g),a=0,f=0,g=0,i=0,a=0;a<b.length;++a){if(!b[a])continue;switch(m[a]){case "%d":case "%e":e=parseInt(b[a],10);break;case "%m":d=parseInt(b[a],10)-1;break;case "%Y":case "%y":c=parseInt(b[a],10);c<100&&(c+=c>29?1900:2e3);break;case "%b":case "%B":for(f=0;f<12;++f)if(Calendar._MN[f].substr(0,b[a].length).toLowerCase()==b[a].toLowerCase()){d=f;break}break;case "%H":case "%I":case "%k":case "%l":g=parseInt(b[a],10);break;case "%P":case "%p":if(/pm/i.test(b[a])&&g<12)g+=12;else if(/am/i.test(b[a])&&g>=12)g-=12;break;case "%M":i=parseInt(b[a],10)}}if(isNaN(c))c=h.getFullYear();if(isNaN(d))d=h.getMonth();if(isNaN(e))e=h.getDate();if(isNaN(g))g=h.getHours();if(isNaN(i))i=h.getMinutes();if(c!=0&&d!=-1&&e!=0)return new Date(c,d,e,g,i,0);c=0;d=-1;e=0;for(a=0;a<b.length;++a)if(b[a].search(/[a-zA-Z]+/)!=-1){var j=-1;for(f=0;f<12;++f)if(Calendar._MN[f].substr(0,b[a].length).toLowerCase()==b[a].toLowerCase()){j=f;break}if(j!=-1){if(d!=-1)e=d+1;d=j}}else if(parseInt(b[a],10)<=12&&d==-1)d=b[a]-1;else if(parseInt(b[a],10)>31&&c==0){c=parseInt(b[a],10);c<100&&(c+=c>29?1900:2e3)}else if(e==0)e=b[a];if(c==0)c=h.getFullYear();if(d!=-1&&e!=0)return new Date(c,d,e,g,i,0);return h};Date.prototype.getMonthDays=function(a){var b=this.getFullYear();if(typeof a=="undefined")a=this.getMonth();if(0==b%4&&(0!=b%100||0==b%400)&&a==1)return 29;else return Date._MD[a]};Date.prototype.getDayOfYear=function(){var c=new Date(this.getFullYear(),this.getMonth(),this.getDate(),0,0,0),a=new Date(this.getFullYear(),0,0,0,0,0),b=c-a;return Math.floor(b/Date.DAY)};Date.prototype.getWeekNumber=function(){var a=new Date(this.getFullYear(),this.getMonth(),this.getDate(),0,0,0),b=a.getDay();a.setDate(a.getDate()-(b+6)%7+3);var c=a.valueOf();a.setMonth(0);a.setDate(4);return Math.round((c-a.valueOf())/(7*8.64e7))+1};Date.prototype.equalsTo=function(a){return this.getFullYear()==a.getFullYear()&&this.getMonth()==a.getMonth()&&this.getDate()==a.getDate()&&this.getHours()==a.getHours()&&this.getMinutes()==a.getMinutes()};Date.prototype.setDateOnly=function(b){var a=new Date(b);this.setDate(1);this.setFullYear(a.getFullYear());this.setMonth(a.getMonth());this.setDate(a.getDate())};Date.prototype.print=function(d){var f=this.getMonth(),h=this.getDate(),p=this.getFullYear(),n=this.getWeekNumber(),j=this.getDay(),a={},b=this.getHours(),m=b>=12,c=m?b-12:b,e=this.getDayOfYear();if(c==0)c=12;var k=this.getMinutes(),l=this.getSeconds();a["%a"]=Calendar._SDN[j];a["%A"]=Calendar._DN[j];a["%b"]=Calendar._SMN[f];a["%B"]=Calendar._MN[f];a["%C"]=1+Math.floor(p/100);a["%d"]=h<10?"0"+h:h;a["%e"]=h;a["%H"]=b<10?"0"+b:b;a["%I"]=c<10?"0"+c:c;a["%j"]=e<100?e<10?"00"+e:"0"+e:e;a["%k"]=b;a["%l"]=c;a["%m"]=f<9?"0"+(1+f):1+f;a["%M"]=k<10?"0"+k:k;a["%n"]="\n";a["%p"]=m?"PM":"AM";a["%P"]=m?"pm":"am";a["%s"]=Math.floor(this.getTime()/1e3);a["%S"]=l<10?"0"+l:l;a["%t"]="\t";a["%U"]=a["%W"]=a["%V"]=n<10?"0"+n:n;a["%u"]=j+1;a["%w"]=j;a["%y"]=(""+p).substr(2,2);a["%Y"]=p;a["%%"]="%";var g=/%./g;if(!Calendar.is_ie5&&!Calendar.is_khtml)return d.replace(g,function(b){return a[b]||b});for(var o=d.match(g),i=0;i<o.length;i++){var q=a[o[i]];if(q){g=new RegExp(o[i],"g");d=d.replace(g,q)}}return d};Date.prototype.__msh_oldSetFullYear=Date.prototype.setFullYear;Date.prototype.setFullYear=function(b){var a=new Date(this);a.__msh_oldSetFullYear(b);a.getMonth()!=this.getMonth()&&this.setDate(28);this.__msh_oldSetFullYear(b)};window._dynarch_popupCalendar=null;function catcalc(c){var e=c.date,b=e.getTime(),a=document.getElementById("f_calcdate");if(a==c.params.inputField){a=document.getElementById("f_date_a");b-=Date.WEEK}else b+=Date.WEEK;var d=new Date(b);a.value=d.print("%Y-%m-%d %H:%M")}Calendar._DN=["S&oslash;ndag","Mandag","Tirsdag","Onsdag","Torsdag","Fredag","L&oslash;rdag","S&oslash;ndag"];Calendar._SDN=["S&oslash;n","Man","Tir","Ons","Tor","Fre","L&oslash;r","S&oslash;n"];Calendar._MN=["Januar","Februar","Marts","April","Maj","Juni","Juli","August","September","Oktober","November","December"];Calendar._SMN=["Jan","Feb","Mar","Apr","Maj","Jun","Jul","Aug","Sep","Okt","Nov","Dec"];Calendar._TT={};Calendar._TT["INFO"]="Om Kalenderen";Calendar._TT["ABOUT"]="DHTML Date/Time Selector\n(c) dynarch.com 2002-2005 / Author: Mihai Bazon\nFor den seneste version bes&oslash:g: http://www.dynarch.com/projects/calendar/\n";+"Distribueret under GNU LGPL. Se http://gnu.org/licenses/lgpl.html for detajler."+"\n\nValg af dato:\n- Brug «, » knapperne for at v&aelig;lge &aring;r\n- Brug "+String.fromCharCode(8249)+", "+String.fromCharCode(8250)+" knapperne for at v&aelig;lge m&aring;ned\n- Hold knappen p&aring; musen nede p&aring; knapperne ovenfor for hurtigere valg.";Calendar._TT["ABOUT_TIME"]="\n\nValg af tid:\n- Klik p&aring; en vilk&aring;rlig del for st&oslash;rre v&aelig;rdi\n- eller Shift-klik for for mindre v&aelig;rdi\n- eller klik og tr&aelig;k for hurtigere valg.";Calendar._TT["PREV_YEAR"]="Et &aring;r tilbage (hold for menu)";Calendar._TT["PREV_MONTH"]="En m&aring;ned tilbage (hold for menu)";Calendar._TT["GO_TODAY"]="G&aring; til i dag";Calendar._TT["NEXT_MONTH"]="En m&aring;ned frem (hold for menu)";Calendar._TT["NEXT_YEAR"]="Et &aring;r frem (hold for menu)";Calendar._TT["SEL_DATE"]="V&aelig;lg dag";Calendar._TT["DRAG_TO_MOVE"]="Tr&aelig;k vinduet";Calendar._TT["PART_TODAY"]=" (i dag)";Calendar._TT["DAY_FIRST"]="Vis %s f&oslash;rst";Calendar._TT["WEEKEND"]="0,6";Calendar._TT["CLOSE"]="Luk";Calendar._TT["TODAY"]="I dag";Calendar._TT["TIME_PART"]="(Shift-)klik eller tr&aelig;k for at &aelig;ndre v&aelig;rdi";Calendar._TT["DEF_DATE_FORMAT"]="%d-%m-%Y";Calendar._TT["TT_DATE_FORMAT"]="%a, %b %e";Calendar._TT["WK"]="Uge";Calendar._TT["TIME"]="Tid:";Calendar.setup=function(a){function b(b,c){if(typeof a[b]=="undefined")a[b]=c}b("inputField",null);b("displayArea",null);b("button",null);b("eventName","click");b("ifFormat","%Y/%m/%d");b("daFormat","%Y/%m/%d");b("singleClick",true);b("disableFunc",null);b("dateStatusFunc",a["disableFunc"]);b("dateText",null);b("firstDay",null);b("align","Br");b("range",[1900,2999]);b("weekNumbers",true);b("flat",null);b("flatCallback",null);b("onSelect",null);b("onClose",null);b("onUpdate",null);b("date",null);b("showsTime",false);b("timeFormat","24");b("electric",true);b("step",2);b("position",null);b("cache",false);b("showOthers",false);b("multiple",null);var d=["inputField","displayArea","button"];for(var e in d)if(typeof a[d[e]]=="string")a[d[e]]=document.getElementById(a[d[e]]);if(!(a.flat||a.multiple||a.inputField||a.displayArea||a.button)){alert("Calendar.setup:\n  Nothing to setup (no fields found).  Please check your code");return false}function f(b){var a=b.params,c=b.dateClicked||a.electric;if(c&&a.inputField){a.inputField.value=b.date.print(a.ifFormat);typeof a.inputField.onchange=="function"&&a.inputField.onchange()}if(c&&a.displayArea)a.displayArea.innerHTML=b.date.print(a.daFormat);c&&typeof a.onUpdate=="function"&&a.onUpdate(b);if(c&&a.flat)typeof a.flatCallback=="function"&&a.flatCallback(b);c&&a.singleClick&&b.dateClicked&&b.callCloseHandler()}if(a.flat!=null){if(typeof a.flat=="string")a.flat=document.getElementById(a.flat);if(!a.flat){alert("Calendar.setup:\n  Flat specified but can't find parent.");return false}var c=new Calendar(a.firstDay,a.date,a.onSelect||f);c.showsOtherMonths=a.showOthers;c.showsTime=a.showsTime;c.time24=a.timeFormat=="24";c.params=a;c.weekNumbers=a.weekNumbers;c.setRange(a.range[0],a.range[1]);c.setDateStatusHandler(a.dateStatusFunc);c.getDateText=a.dateText;a.ifFormat&&c.setDateFormat(a.ifFormat);a.inputField&&typeof a.inputField.value=="string"&&c.parseDate(a.inputField.value);c.create(a.flat);c.show();return false}var g=a.button||a.displayArea||a.inputField;g["on"+a.eventName]=function(){var c=a.inputField||a.displayArea,e=a.inputField?a.ifFormat:a.daFormat,d=false,b=window.calendar;if(c)a.date=Date.parseDate(c.value||c.innerHTML,e);if(!(b&&a.cache)){window.calendar=b=new Calendar(a.firstDay,a.date,a.onSelect||f,a.onClose||function(a){a.hide()});b.showsTime=a.showsTime;b.time24=a.timeFormat=="24";b.weekNumbers=a.weekNumbers;d=true}else{a.date&&b.setDate(a.date);b.hide()}if(a.multiple){b.multiple={};for(var h=a.multiple.length;--h>=0;){var g=a.multiple[h],i=g.print("%Y%m%d");b.multiple[i]=g}}b.showsOtherMonths=a.showOthers;b.yearStep=a.step;b.setRange(a.range[0],a.range[1]);b.params=a;b.setDateStatusHandler(a.dateStatusFunc);b.getDateText=a.dateText;b.setDateFormat(e);d&&b.create();b.refresh();if(!a.position)b.showAtElement(a.button||a.displayArea||a.inputField,a.align);else b.showAt(a.position[0],a.position[1]);return false};return c};var swfobject=function(){var c="undefined",h="object",F="Shockwave Flash",z="ShockwaveFlash.ShockwaveFlash",w="application/x-shockwave-flash",E="SWFObjectExprInst",d=window,b=document,i=navigator,v=[],g=[],t=[],l=[],m,x=null,n=null,u=null,p=false,k=false,a=function(){var o=typeof b.getElementById!=c&&typeof b.getElementsByTagName!=c&&typeof b.createElement!=c,e=[0,0,0],a=null;if(typeof i.plugins!=c&&typeof i.plugins[F]==h){a=i.plugins[F].description;if(a&&!(typeof i.mimeTypes!=c&&i.mimeTypes[w]&&!i.mimeTypes[w].enabledPlugin)){a=a.replace(/^.*\s+(\S+\s+\S+$)/,"$1");e[0]=parseInt(a.replace(/^(.*)\..*$/,"$1"),10);e[1]=parseInt(a.replace(/^.*\.(.*)\s.*$/,"$1"),10);e[2]=/r/.test(a)?parseInt(a.replace(/^.*r(.*)$/,"$1"),10):0}}else if(typeof d.ActiveXObject!=c){var f=null,l=false;try{f=new ActiveXObject(z+".7")}catch(k){try{f=new ActiveXObject(z+".6");e=[6,0,21];f.AllowScriptAccess="always"}catch(k){if(e[0]==6)l=true}if(!l)try{f=new ActiveXObject(z)}catch(k){}}if(!l&&f)try{a=f.GetVariable("$version");if(a){a=a.split(" ")[1].split(",");e=[parseInt(a[0],10),parseInt(a[1],10),parseInt(a[2],10)]}}catch(k){}}var g=i.userAgent.toLowerCase(),j=i.platform.toLowerCase(),n=/webkit/.test(g)?parseFloat(g.replace(/^.*webkit\/(\d+(\.\d+)?).*$/,"$1")):false,m=false,q=j?/win/.test(j):/win/.test(g),p=j?/mac/.test(j):/mac/.test(g);m=true;return {w3cdom:o,pv:e,webkit:n,ie:m,win:q,mac:p}}(),P=function(){if(!a.w3cdom)return;r(K);if(a.ie&&a.win)try{b.write("<script id=__ie_ondomload defer=true src=//:></sc"+"ript>");m=e("__ie_ondomload");m&&s(m,"onreadystatechange",M)}catch(d){}if(a.webkit&&typeof b.readyState!=c)x=setInterval(function(){/loaded|complete/.test(b.readyState)&&q()},10);typeof b.addEventListener!=c&&b.addEventListener("DOMContentLoaded",q,null);G(q)}();function M(){if(m.readyState=="complete"){m.parentNode.removeChild(m);q()}}function q(){if(p)return;if(a.ie&&a.win){var g=f("span");try{var d=b.getElementsByTagName("body")[0].appendChild(g);d.parentNode.removeChild(d)}catch(h){return}}p=true;if(x){clearInterval(x);x=null}for(var e=v.length,c=0;c<e;c++)v[c]()}function r(a){if(p)a();else v[v.length]=a}function G(a){if(typeof d.addEventListener!=c)d.addEventListener("load",a,false);else if(typeof b.addEventListener!=c)b.addEventListener("load",a,false);else if(typeof d.attachEvent!=c)s(d,"onload",a);else if(typeof d.onload=="function"){var e=d.onload;d.onload=function(){e();a()}}else d.onload=a}function K(){for(var f=g.length,b=0;b<f;b++){var d=g[b].id;if(a.pv[0]>0){var c=e(d);if(c){g[b].width=c.getAttribute("width")?c.getAttribute("width"):"0";g[b].height=c.getAttribute("height")?c.getAttribute("height"):"0";if(o(g[b].swfVersion)){a.webkit&&a.webkit<312&&N(c);j(d,true)}else if(g[b].expressInstall&&!k&&o("6.0.65")&&(a.win||a.mac))D(g[b]);else L(c)}}else j(d,true)}}function N(i){var g=i.getElementsByTagName(h)[0];if(g){var e=f("embed"),d=g.attributes;if(d)for(var j=d.length,b=0;b<j;b++)if(d[b].nodeName=="DATA")e.setAttribute("src",d[b].nodeValue);else e.setAttribute(d[b].nodeName,d[b].nodeValue);var c=g.childNodes;if(c)for(var k=c.length,a=0;a<k;a++)c[a].nodeType==1&&c[a].nodeName=="PARAM"&&e.setAttribute(c[a].getAttribute("name"),c[a].getAttribute("value"));i.parentNode.replaceChild(e,i)}}function D(c){k=true;var g=e(c.id);if(g){if(c.altContentId){var j=e(c.altContentId);if(j){n=j;u=c.altContentId}}else n=y(g);if(!/%$/.test(c.width)&&parseInt(c.width,10)<310)c.width="310";if(!/%$/.test(c.height)&&parseInt(c.height,10)<137)c.height="137";b.title=b.title.slice(0,47)+" - Flash Player Installation";var p=a.ie&&a.win?"ActiveX":"PlugIn",l=b.title,m="MMredirectURL="+d.location+"&MMplayerType="+p+"&MMdoctitle="+l,h=c.id;if(a.ie&&a.win&&g.readyState!=4){var i=f("div");h+="SWFObjectNew";i.setAttribute("id",h);g.parentNode.insertBefore(i,g);g.style.display="none";var o=function(){g.parentNode.removeChild(g)};s(d,"onload",o)}A({data:c.expressInstall,id:E,width:c.width,height:c.height},{flashvars:m},h)}}function L(b){if(a.ie&&a.win&&b.readyState!=4){var c=f("div");b.parentNode.insertBefore(c,b);c.parentNode.replaceChild(y(b),c);b.style.display="none";var e=function(){b.parentNode.removeChild(b)};s(d,"onload",e)}else b.parentNode.replaceChild(y(b),b)}function y(g){var d=f("div");if(a.win&&a.ie)d.innerHTML=g.innerHTML;else{var e=g.getElementsByTagName(h)[0];if(e){var c=e.childNodes;if(c)for(var i=c.length,b=0;b<i;b++)!(c[b].nodeType==1&&c[b].nodeName=="PARAM")&&!(c[b].nodeType==8)&&d.appendChild(c[b].cloneNode(true))}}return d}function A(b,d,u){var q,m=e(u);if(m){if(typeof b.id==c)b.id=u;if(a.ie&&a.win){var r="";for(var g in b)if(b[g]!=Object.prototype[g])if(g.toLowerCase()=="data")d.movie=b[g];else if(g.toLowerCase()=="styleclass")r+=' class="'+b[g]+'"';else if(g.toLowerCase()!="classid")r+=" "+g+'="'+b[g]+'"';var s="";for(var p in d)if(d[p]!=Object.prototype[p])s+='<param name="'+p+'" value="'+d[p]+'" />';m.outerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'+r+">"+s+"</object>";t[t.length]=b.id;q=e(b.id)}else if(a.webkit&&a.webkit<312){var j=f("embed");j.setAttribute("type",w);for(var i in b)if(b[i]!=Object.prototype[i])if(i.toLowerCase()=="data")j.setAttribute("src",b[i]);else if(i.toLowerCase()=="styleclass")j.setAttribute("class",b[i]);else i.toLowerCase()!="classid"&&j.setAttribute(i,b[i]);for(var o in d)if(d[o]!=Object.prototype[o])o.toLowerCase()!="movie"&&j.setAttribute(o,d[o]);m.parentNode.replaceChild(j,m);q=j}else{var l=f(h);l.setAttribute("type",w);for(var k in b)if(b[k]!=Object.prototype[k])if(k.toLowerCase()=="styleclass")l.setAttribute("class",b[k]);else k.toLowerCase()!="classid"&&l.setAttribute(k,b[k]);for(var n in d)d[n]!=Object.prototype[n]&&n.toLowerCase()!="movie"&&J(l,n,d[n]);m.parentNode.replaceChild(l,m);q=l}}return q}function J(d,b,c){var a=f("param");a.setAttribute("name",b);a.setAttribute("value",c);d.appendChild(a)}function I(c){var b=e(c);if(b&&(b.nodeName=="OBJECT"||b.nodeName=="EMBED"))if(a.ie&&a.win)if(b.readyState==4)B(c);else d.attachEvent("onload",function(){B(c)});else b.parentNode.removeChild(b)}function B(c){var a=e(c);if(a){for(var b in a)if(typeof a[b]=="function")a[b]=null;a.parentNode.removeChild(a)}}function e(d){var a=null;try{a=b.getElementById(d)}catch(c){}return a}function f(a){return b.createElement(a)}function s(c,a,b){c.attachEvent(a,b);l[l.length]=[c,a,b]}function o(d){var c=a.pv,b=d.split(".");b[0]=parseInt(b[0],10);b[1]=parseInt(b[1],10)||0;b[2]=parseInt(b[2],10)||0;return c[0]>b[0]||c[0]==b[0]&&c[1]>b[1]||c[0]==b[0]&&c[1]==b[1]&&c[2]>=b[2]?true:false}function H(i,g){if(a.ie&&a.mac)return;var j=b.getElementsByTagName("head")[0],d=f("style");d.setAttribute("type","text/css");d.setAttribute("media","screen");!(a.ie&&a.win)&&typeof b.createTextNode!=c&&d.appendChild(b.createTextNode(i+" {"+g+"}"));j.appendChild(d);if(a.ie&&a.win&&typeof b.styleSheets!=c&&b.styleSheets.length>0){var e=b.styleSheets[b.styleSheets.length-1];typeof e.addRule==h&&e.addRule(i,g)}}function j(a,c){var b=c?"visible":"hidden";if(p&&e(a))e(a).style.visibility=b;else H("#"+a,"visibility:"+b)}function C(a){var c=/[\\\"<>\.;]/,b=c.exec(a)!=null;return b?encodeURIComponent(a):a}var O=function(){a.ie&&a.win&&window.attachEvent("onunload",function(){for(var g=l.length,b=0;b<g;b++)l[b][0].detachEvent(l[b][1],l[b][2]);for(var f=t.length,c=0;c<f;c++)I(t[c]);for(var e in a)a[e]=null;a=null;for(var d in swfobject)swfobject[d]=null;swfobject=null})}();return {registerObject:function(c,d,e){if(!a.w3cdom||!c||!d)return;var b={};b.id=c;b.swfVersion=d;b.expressInstall=e?e:false;g[g.length]=b;j(c,false)},getObjectById:function(g){var f=null;if(a.w3cdom){var b=e(g);if(b){var d=b.getElementsByTagName(h)[0];if(!d||d&&typeof b.SetVariable!=c)f=b;else if(typeof d.SetVariable!=c)f=d}}return f},embedSWF:function(u,b,m,n,s,t,e,l,g){if(!a.w3cdom||!u||!b||!m||!n||!s)return;m+="";n+="";if(o(s)){j(b,false);var d={};if(g&&typeof g===h)for(var q in g)if(g[q]!=Object.prototype[q])d[q]=g[q];d.data=u;d.width=m;d.height=n;var i={};if(l&&typeof l===h)for(var p in l)if(l[p]!=Object.prototype[p])i[p]=l[p];if(e&&typeof e===h)for(var f in e)if(e[f]!=Object.prototype[f])if(typeof i.flashvars!=c)i.flashvars+="&"+f+"="+e[f];else i.flashvars=f+"="+e[f];r(function(){A(d,i,b);d.id==b&&j(b,true)})}else if(t&&!k&&o("6.0.65")&&(a.win||a.mac)){k=true;j(b,false);r(function(){var a={};a.id=a.altContentId=b;a.width=m;a.height=n;a.expressInstall=t;D(a)})}},getFlashPlayerVersion:function(){return {major:a.pv[0],minor:a.pv[1],release:a.pv[2]}},hasFlashPlayerVersion:o,createSWF:function(d,c,b){if(a.w3cdom)return A(d,c,b);else return undefined},removeSWF:function(b){a.w3cdom&&I(b)},createCSS:function(c,b){a.w3cdom&&H(c,b)},addDomLoadEvent:r,addLoadEvent:G,getQueryParamValue:function(e){var d=b.location.search||b.location.hash;if(e==null)return C(d);if(d)for(var c=d.substring(1).split("&"),a=0;a<c.length;a++)if(c[a].substring(0,c[a].indexOf("="))==e)return C(c[a].substring(c[a].indexOf("=")+1));return ""},expressInstallCallback:function(){if(k&&n){var b=e(E);if(b){b.parentNode.replaceChild(n,b);if(u){j(u,true);if(a.ie&&a.win)n.style.display="block"}n=null;u=null;k=false}}}}}(),loadingImage="../images/icons/loading_default.gif",closeButton="../images/icons/close.gif";function getPageScroll(){var a;if(self.pageYOffset)a=self.pageYOffset;else if(document.documentElement&&document.documentElement.scrollTop)a=document.documentElement.scrollTop;else if(document.body)a=document.body.scrollTop;arrayPageScroll=["",a];return arrayPageScroll}function getPageSize(){var c,d;if(window.innerHeight&&window.scrollMaxY){c=document.body.scrollWidth;d=window.innerHeight+window.scrollMaxY}else if(document.body.scrollHeight>document.body.offsetHeight){c=document.body.scrollWidth;d=document.body.scrollHeight}else{c=document.body.offsetWidth;d=document.body.offsetHeight}var b,a;if(self.innerHeight){b=self.innerWidth;a=self.innerHeight}else if(document.documentElement&&document.documentElement.clientHeight){b=document.documentElement.clientWidth;a=document.documentElement.clientHeight}else if(document.body){b=document.body.clientWidth;a=document.body.clientHeight}if(d<a)pageHeight=a;else pageHeight=d;if(c<b)pageWidth=b;else pageWidth=c;arrayPageSize=[pageWidth,pageHeight,b,a];return arrayPageSize}function pause(b){var a=new Date,c=a.getTime()+b;while(true){a=new Date;if(a.getTime()>c)return}}function getKey(a){if(a==null)keycode=event.keyCode;else keycode=a.which;key=String.fromCharCode(keycode).toLowerCase();key=="x"&&hideLightbox()}function listenKey(){document.onkeypress=getKey}function showLightbox(c){var f=document.getElementById("overlay"),d=document.getElementById("lightbox"),e=document.getElementById("lightboxCaption"),h=document.getElementById("lightboxImage"),a=document.getElementById("loadingImage"),j=document.getElementById("lightboxDetails"),b=getPageSize(),g=getPageScroll();if(a){a.style.top=g[1]+(b[3]-35-a.height)/2+"px";a.style.left=(b[0]-20-a.width)/2+"px";a.style.display="block"}f.style.height=b[1]+"px";f.style.display="block";imgPreload=new Image;imgPreload.onload=function(){h.src=c.href;var l=g[1]+(b[3]-35-imgPreload.height)/2,k=(b[0]-20-imgPreload.width)/2;d.style.top=l<0?"0px":l+"px";d.style.left=k<0?"0px":k+"px";j.style.width=imgPreload.width+"px";if(c.getAttribute("title")){e.style.display="block";e.innerHTML=c.getAttribute("title")}else e.style.display="none";navigator.appVersion.indexOf("MSIE")!=-1&&pause(250);if(a)a.style.display="none";selects=document.getElementsByTagName("select");for(i=0;i!=selects.length;i++)selects[i].style.visibility="hidden";d.style.display="block";b=getPageSize();f.style.height=b[1]+"px";listenKey();mouseCov&&renderCover(h);return false};imgPreload.src=c.href;hideBuiltInControls()}var clickToEnlargeIcon;function showMagnifyIcon(c,e){var a=getElementPosition(c);a[0];a[1];if(!clickToEnlargeIcon){clickToEnlargeIcon=document.getElementById("clickToEnlargeIcon");if(navigator.appVersion.indexOf("MSIE")>-1){var b=navigator.appVersion,f=b.length,d=b.indexOf("MSIE");if(parseInt(b.substring(d+5,d+6))<7)clickToEnlargeIcon.src="../images/icons/magnify.gif"}clickToEnlargeIcon.style.display="block";clickToEnlargeIcon.onmouseout=function(){hideMagnifyIcon()}}clickToEnlargeIcon.imgId=e;clickToEnlargeIcon.onclick=function(){showLightbox(document.getElementById("lnkArticleImage"));document.getElementById("clickToEnlargeIcon").style.display="none"};clickToEnlargeIcon.style.display="block";clickToEnlargeIcon.style.left=parseInt(a[0])+parseInt(c.offsetWidth)-37+"px";clickToEnlargeIcon.style.top=parseInt(a[1])+parseInt(c.offsetHeight)-38+"px"}function hideMagnifyIcon(){if(clickToEnlargeIcon)clickToEnlargeIcon.style.display="none"}var coverId="_lightboxcover";function renderCover(b){var a=document.getElementById(coverId);if(!a){var c=getElementPosition(document.getElementById(b.id));a=document.createElement("img");document.body.appendChild(a);a.src="../images/icons/pot.gif";a.id=coverId;a.style.width=parseInt(b.offsetWidth)+"px";a.style.height=parseInt(b.offsetHeight)+"px";a.style.left=c[0]+"px";a.style.top=c[1]+"px";a.style.position="absolute";a.style.display="block";a.style.zIndex=300;a.style.cursor="pointer";if(window.attachEvent)a.attachEvent("onclick",initCloseLightbox);else a.addEventListener("click",initCloseLightbox,false)}else a.style.display="block"}function initCloseLightbox(){var a=document.getElementById(coverId);if(a){if(mouseCov)a.style.display="none";hideLightbox()}}function hideLightbox(){var a=document.getElementById(coverId);if(mouseCov&&a&&a.style.display=="block"){initCloseLightbox();event.cancelBubble=true}objOverlay=document.getElementById("overlay");objLightbox=document.getElementById("lightbox");objOverlay.style.display="none";objLightbox.style.display="none";selects=document.getElementsByTagName("select");for(i=0;i!=selects.length;i++)selects[i].style.visibility="visible";document.onkeypress="";showHiddenControls()}function initLightbox(){if(!document.getElementsByTagName)return;for(var j=document.getElementsByTagName("a"),f=0;f<j.length;f++){var d=j[f];if(d.getAttribute("href")&&d.getAttribute("rel")=="lightbox"){var p=j[f].firstChild.getAttribute("id");d.onclick=function(){showLightbox(this);return false};d.firstChild.onmouseover=function(){showMagnifyIcon(this,this.getAttribute("imageId"),arguments[0])};d.onmouseout=function(){eventObj=arguments[0]?arguments[0]:event;var a=eventObj.relatedTarget?eventObj.relatedTarget:eventObj.toElement?eventObj.toElement:null;a&&a.id!="clickToEnlargeIcon"&&hideMagnifyIcon(this,arguments[0])}}}var k=document.getElementsByTagName("body").item(0),a=document.createElement("div");a.setAttribute("id","overlay");a.onclick=function(){hideLightbox();return false};a.style.display="none";a.style.position="absolute";a.style.top="0";a.style.left="0";a.style.zIndex="90";a.style.width="100%";k.insertBefore(a,k.firstChild);var o=getPageSize(),n=getPageScroll(),h=new Image;h.onload=function(){var c=document.createElement("a");c.setAttribute("href","#");c.onclick=function(){hideLightbox();return false};a.appendChild(c);var b=document.createElement("img");b.src=loadingImage;b.setAttribute("id","loadingImage");b.style.position="absolute";b.style.zIndex="150";c.appendChild(b);h.onload=function(){};return false};h.src=loadingImage;var b=document.createElement("div");b.setAttribute("id","lightbox");b.style.display="none";b.style.position="absolute";b.style.zIndex="100";k.insertBefore(b,a.nextSibling);var c=document.createElement("a");c.setAttribute("href","#");c.setAttribute("title","Click to close");c.onclick=function(){hideLightbox();return false};b.appendChild(c);var l=new Image;l.onload=function(){var a=document.createElement("img");a.src=closeButton;a.setAttribute("id","closeButton");a.style.position="absolute";a.style.zIndex="200";c.appendChild(a);return false};l.src=closeButton;var m=document.createElement("img");m.setAttribute("id","lightboxImage");c.appendChild(m);var e=document.createElement("div");e.setAttribute("id","lightboxDetails");b.appendChild(e);var i=document.createElement("div");i.setAttribute("id","lightboxCaption");i.style.display="none";e.appendChild(i);var g=document.createElement("div");g.setAttribute("id","keyboardMsg");g.innerHTML=getStringFromDictionary("visartikel_TrykPaa","*")+' <a href="#" onclick="hideLightbox(); return false;"><kbd>x</kbd></a> '+getStringFromDictionary("visartikel_ForAtLukkeVinduet","*");e.appendChild(g)}function addLoadEvent(a){var b=window.onload;if(typeof window.onload!="function")window.onload=a;else window.onload=function(){b();a()}}var MemoPopup=function(){this.timeout=-1;this.marginTop=10;this.marginBottom=10;this.offsetX;this.offsetY;this.headline;this.text;this.minMemoPopupHeight=200;this.offsetElemYID="tdArticleBannerContainer";this.offsetElemXID="tdLeftMenu";this.offsetElemX;this.offsetElemY;this.divMemoSlot;this.memoPopupHead;this.memoPopupBody;this.memoPopupText;this.popupDelay=1e3;this.hiddenIFrames;this.render=function(){$("#divMemoContainer").css("visibility","hidden");var a=document.createElement("div");a.id="divMemoContainer";a.style.width="558px";a.style.overflow="auto";a.style.position="absolute";a.style.top="150px";a.style.left="150px";document.body.appendChild(a);var e=document.createElement("div");e.style.width="558px";e.style.height="76px";e.style.backgroundImage="url('"+applicationRootPath+"/images/background/memo_bg_top."+(supportsPng()==true?"png":"gif")+"')";e.backgroundRepeat="no-repeat";a.appendChild(e);var c=document.createElement("div");c.style.fontWeight="bold";c.style.display="block";c.style.color="#7f7f7f";if(document.all)c.style.styleFloat="left";else c.style.cssFloat="left";c.innerHTML=this.headline;c.style.fontFamily="arial";c.style.fontSize="15px";c.style.marginTop="30px";c.style.marginLeft="32px";var b=document.createElement("img");b.src=applicationRootPath+"/images/buttons/memo_close.gif";b.style.display="block";if(document.all)b.style.styleFloat="right";else b.style.cssFloat="right";b.style.marginRight="28px";b.style.marginTop="20px";b.onmouseover=function(){imageOver(this)};b.style.cursor="pointer";b.onmouseout=function(){imageOut(this)};b.onclick=function(){document.getElementById("divMemoContainer").style.display="none"};b.setAttribute("title",getStringFromDictionary("memoPopup_Luk","*"));b.setAttribute("alt",getStringFromDictionary("memoPopup_Luk","*"));e.appendChild(b);e.appendChild(c);var f=document.createElement("div");f.style.width="558px";f.style.overflow="auto";f.style.backgroundImage="url('"+applicationRootPath+"/images/background/memo_bg_content."+(supportsPng()==true?"png":"gif")+"')";f.style.backgroundRepeat="repeat-y";a.appendChild(f);var d=document.createElement("div");d.style.width="485px";d.innerHTML=this.text;d.style.overflow="auto";d.style.color="#7f7f7f";d.style.fontFamily="arial";d.style.fontSize="14px";d.style.marginLeft="32px";f.appendChild(d);var g=document.createElement("div");g.style.backgroundImage="url('"+applicationRootPath+"/images/background/memo_bg_bottom."+(supportsPng()==true?"png":"gif")+"')";g.backgroundRepeat="no-repeat";g.style.width="558px";g.style.height="82px";a.appendChild(g);a.style.zIndex="450";var j=parseInt(document.documentElement.scrollTop);a.style.top=parseInt(document.documentElement.clientHeight)>parseInt(a.offsetHeight)?j+parseInt((parseInt(document.documentElement.clientHeight)-parseInt(a.offsetHeight))/2)+"px":j+"px";a.style.left="210px";$("#divMemoContainer").css("display","none");$("#divMemoContainer").css("visibility","visible");$("#divMemoContainer").slideDown("slow");this.hiddenIFrames=[];var h=document.getElementsByTagName("iframe");if(h&&h.length>0)for(var i=0;i<h.length;i++){h[i].style.visibility="hidden";this.hiddenIFrames.push(h[i])}};this.init=function(b,c){var a=new Image;a.src=applicationRootPath+"/images/background/memo_bg_top.png";a=new Image;a.src=applicationRootPath+"/images/background/memo_bg_content.png";a=new Image;a.src=applicationRootPath+"/images/background/memo_bg_bottom.png";applicationRootPath+"/images/background/memo_bg_content.png";applicationRootPath+"/images/background/memo_bg_bottom.png";this.headline=b;this.text=c;this.offsetElemX=document.getElementById(this.offsetElemXID);this.offsetElemY=document.getElementById(this.offsetElemYID);window.setTimeout(function(){memPopup.render()},memPopup.popupDelay)}},imgBrowser;function ImageBrowser(){this.imageBack;this.imageNext;this.lnkBack;this.lnkNext;this.pages=[];var b;this.images=[];this.currentImageIndex=0;this.slotLeft=document.getElementById("imgPageLeft");this.slotRight=document.getElementById("imgPageRight");this.pnlPageCountLeft=document.getElementById("pnlPageCountLeft");this.pnlPageCountRight=document.getElementById("pnlPageCountRight");this.lnkOpenPageLeft=document.getElementById("lnkOpenPageLeft");this.lnkOpenPageRight=document.getElementById("lnkOpenPageRight");this.pnlPageNumbers=document.getElementById("pnlPageNumbers");this.imageIndexChanged=function(){var a=arguments[0];if(a){var b=a.srcElement?a.srcElement:a.target,c=b.getAttribute("id");switch(c){case "imgBack":imgBrowser.changeImgIndex(-1);break;case "imgNext":imgBrowser.changeImgIndex(1)}}setPositionByIndex(imgBrowser.currentImageIndex)};this.addImage=function(a){this.images.push(a);if(this.pages.length>0&&this.pages[this.pages.length-1].length<2)this.pages[this.pages.length-1].push(a);else this.pages.push(new Array(a))};this.changeImgIndex=function(a){if(this.currentImageIndex+a>=0&&this.currentImageIndex+a<this.pages.length-1){this.currentImageIndex+=a;if(parseInt(a)<0)this.renderBegin();else if(parseInt(a)>0)this.renderBegin();else parseInt(a)==0&&this.renderBegin()}};this.renderBegin=function(){this.renderEnd()};this.renderEnd=function(){var d=false;if(this.currentImageIndex>=0&&this.currentImageIndex<this.images.length-1){this.slotLeft.src=this.pages[this.currentImageIndex][0];var b=this.pages[this.currentImageIndex][0].replace("thumb","PDF");b=b.replace(".gif",".pdf").replace("../FINDMIGIKKE/sider/","");this.lnkOpenPageLeft.setAttribute("pdfFile",b);this.lnkOpenPageLeft.href="viewPDF.aspx?pdfFile="+b;if(this.slotLeft.style.display=="none")this.slotLeft.style.display="block"}if(this.pages[this.currentImageIndex].length>1){this.slotRight.src=this.pages[this.currentImageIndex][1];var a=this.pages[this.currentImageIndex][1].replace("thumb","PDF");a=a.replace(".gif",".pdf").replace("../FINDMIGIKKE/sider/","");this.lnkOpenPageRight.setAttribute("pdfFile",a);this.lnkOpenPageRight.href="viewPDF.aspx?pdfFile="+a;if(this.slotRight.style.display=="none"){this.slotRight.style.display="block";d=true}}else this.slotRight.style.display="none";if(this.images[this.currentImageIndex-1]){this.imgBack.src="../images/icons/linkback.gif";this.imgBack.style.cursor="pointer"}else{this.imgBack.src="../images/icons/linkback_inactive.gif";this.imgBack.style.cursor="default"}if(this.images[this.currentImageIndex+2]){this.imgNext.src="../images/icons/link.gif";this.imgNext.style.cursor="pointer"}else{this.imgNext.src="../images/icons/link_inactive.gif";this.imgNext.style.cursor="default"}this.pnlPageCountLeft.innerHTML=dictionary!=undefined&&dictionary["page"]!=undefined?dictionary["page"]:"Side";this.pnlPageCountLeft.innerHTML+=" "+(2*this.currentImageIndex+1);if(this.currentImageIndex+1<this.images.length){this.pnlPageCountRight.innerHTML=dictionary!=undefined&&dictionary["page"]!=undefined?dictionary["page"]:"Side";this.pnlPageCountRight.innerHTML+=" "+(2*this.currentImageIndex+2)}var c="";if(this.images.length==1)c=dictionary!=undefined&&dictionary["page"]!=undefined?" "+dictionary["page"].toLowerCase()+".":" side.";else c=dictionary!=undefined&&dictionary["pages"]!=undefined?" "+dictionary["pages"].toLowerCase()+".":" sider.";var e=2*this.currentImageIndex+1+" ";e+=this.images.length>1?" "+dictionary["and"]+" "+(2*this.currentImageIndex+2)+" ":" ";this.pnlPageNumbers.innerHTML=e;document.getElementById("pnlTotalPageCount").innerHTML=this.images.length+c;if(d);};this.setCurrentImgIndex=function(a){if(this.images[a])this.currentImageIndex=a;else if(a>=this.images.length-2)this.currentImageIndex=this.images.length-2}}function initImageBrowser(){var a=document.getElementById("imgBack"),b=document.getElementById("imgNext"),c=[a,b];imgBrowser=new ImageBrowser(c);imgBrowser.imgBack=a;imgBrowser.imgNext=b}var count,minX=374,maxX=598,sliderLength=maxX-minX,sliderKnot,sliderUnit;function init(){initiateSlider();var a=document.getElementById("sliderKnot");makeClickable(a);makeDraggable(a)}var imgArr=[],currentPosIndex,minX,maxX,sliderLength,sliderUnit,posArr,imgIndexView;function initiateSlider(){var c=3,b=document.getElementById("sliderBar"),e=document.getElementById("sliderKnot"),f=b.offsetWidth,d=getPosition(b);minX=d.x+c;maxX=d.x+f-e.offsetWidth-c;sliderLength=maxX-minX;sliderUnit=sliderLength/(imgBrowser.pages.length-1);posArr=[];for(var a=0;a<imgBrowser.pages.length;a++)posArr[a]=new Position(minX+Math.round(a*sliderUnit),null);currentPosIndex=0;imgIndexView=document.getElementById("imgIndexView");if(!imgIndexView){imgIndexView=document.createElement("div");imgIndexView.style.width="40px";imgIndexView.style.height="23px";imgIndexView.style.overflowY="hidden";imgIndexView.style.fontSize="9px";imgIndexView.style.backgroundImage="url(../images/background/archive_index_view.gif)";imgIndexView.style.backgroundRepeat="no-repeat";imgIndexView.style.textAlign="center";imgIndexView.style.paddingTop="4px";imgIndexView.style.position="absolute";imgIndexView.style.zIndex="50";imgIndexView.style.display="none";if(isBrowserIE())document.body.firstChild.appendChild(imgIndexView);else document.body.appendChild(imgIndexView)}}function initiateDragDrop(a){sliderKnot=a;makeClickable(sliderKnot);makeDraggable(sliderKnot);count=imgBrowser.pages.length;count--;a.style.position="absolute";sliderUnit=Math.abs(sliderLength/count)}function mouseCoords(a){if(a.pageX||a.pageY)return {x:a.pageX,y:a.pageY};try{return {x:a.clientX+document.body.scrollLeft-document.body.clientLeft,y:a.clientY+document.body.scrollTop-document.body.clientTop}}catch(b){}}document.onmousemove=mouseMove;document.onmouseup=mouseUp;var dragObject=null;function makeClickable(a){a.onmousedown=function(){dragObject=this}}var dragObject=null,mouseOffset=null;function getMouseOffset(d,a){a=a||window.event;var c=getPosition(d),b=mouseCoords(a);return {x:b.x-c.x,y:b.y-c.y}}function getPosition(a){var b=0,c=0;while(a.offsetParent){b+=a.offsetLeft;c+=a.offsetTop;a=a.offsetParent}b+=a.offsetLeft;c+=a.offsetTop;return {x:b,y:c}}function mouseMove(b){if(!dragObject)return;b=b||window.event;var a=mouseCoords(b);if(dragObject){if(dragObject.style.left=="")dragObject.style.left=0+"px";dragObject.style.position="absolute";if(a.x-mouseOffset.x>=minX&&a.x-mouseOffset.x<=maxX)dragObject.style.left=a.x-mouseOffset.x+"px";else dragObject.style.left=a.x-mouseOffset.x<minX?minX+"px":maxX+"px";imageIndex=Math.round((parseInt(dragObject.style.left)-minX)/sliderUnit);currentPosIndex=imageIndex;displayImageIndexPopup(currentPosIndex);return false}}function mouseUp(){dragObject&&beginMove();dragObject=null;if(imgIndexView&&imgIndexView.style.display=="block")if(isBrowserIE())window.setTimeout('imgIndexView.style.display = "none";',150);else imgIndexView.style.display="none"}function displayImageIndexPopup(a){if(imgIndexView.style.display=="none")imgIndexView.style.display="block";imgIndexView.style.top=parseInt(dragObject.offsetTop)-imgIndexView.offsetHeight+"px";imgIndexView.style.left=parseInt(dragObject.offsetLeft)-parseInt(imgIndexView.style.width)/2+parseInt(dragObject.offsetWidth)/2+"px";imgIndexView.innerHTML=2*a+1+"-"+(2*a+2)}function makeDraggable(a){if(!a)return;a.onmousedown=function(a){dragObject=this;mouseOffset=getMouseOffset(this,a);return false}}function navigateKnotByMouseClick(b){b=b||window.event;var c;if(b.pageX)c=b.pageX;else c=b.clientX;var d=document.getElementById("sliderKnot"),a=parseInt(c)-parseInt(d.offsetWidth)/2;if(a<parseInt(minX))a=parseInt(minX);else if(a>parseInt(maxX))a=parseInt(maxX);d.style.left=a+"px";changePageImage()}function setPositionByIndex(b){if(sliderUnit){var a=parseInt(minX)+sliderUnit*b;sliderKnot.style.left=a+"px"}}function changePageImage(){window.setTimeout(function(){dragObject&&imgBrowser.renderBegin();imgBrowser.renderBegin()},20)}function AnimObject(a,d,c,b,e){a.style.position="absolute";this.id="animObj_"+a.getAttribute("id");if(window[this.id]){window.clearTimeout(window["timeout"]);window[this.id]=undefined}this.element=a;this.begin=d;this.finish=c;this.change=this.finish-this.begin;this.duration=b;this.time=e;this.beginAnimation=function(){var a=this.id;window[a]=this;this.setNewPosition()};this.setNewPosition=function(){if(this.begin!=this.finish){this.time++;this.change=this.finish-this.begin;this.begin=Math.round(calcPosition(this.time,this.begin,this.change,this.duration));this.element.style.left=this.begin+"px";var a=this.id;window["timeout"]=window.setTimeout("window['"+a+"'].setNewPosition()",15)}else{imgBrowser.setCurrentImgIndex(currentPosIndex);changePageImage()}};this.dispose=function(){}}var calcPosition=function(a,b,c,d){if((a/=d/2)<1)return c/2*a*a+b;else return -c/2*(--a*(a-2)-1)+b},beginMove=function(b){var d=document.getElementById("sliderKnot"),g=0,a,c;if(b!=null){a=posArr[currentPosIndex].x;c=posArr[b].x}else{a=parseInt(d.style.left);c=posArr[currentPosIndex].x;if(!a)a=posArr[0].x}var h=c-a,f=20,e=new AnimObject(d,a,c,f,g);e.beginAnimation();currentPosIndex=b!=null?b:currentPosIndex};function Position(a,b){this.x=a;this.y=b}function movePos(a){posArr[currentPosIndex+a]&&beginMove(currentPosIndex+a)}function setImageIndexByClickedPosition(a){var a=a?a:window.event;dragObject=document.getElementById("sliderKnot");if(!mouseOffset){mouseOffset={};mouseOffset.x=6}mouseMove(a)}