//Copyright timeanddate.com 2005-2010, do not use without permission
men={};menact=null;elh={};fh={};
menus=[{p:"/",s:[]},{p:"/w",s:[{t:"Main World Clock",u:"orldclock/"},{t:"Extended World Clock",u:"orldclock/full.html"},{t:"Personal World Clock",u:"orldclock/personal.html"},{t:"Fixed Time World Clock",u:"orldclock/fixedform.html"},{t:"Weather and Time",u:"eather/"}]},{p:"/",s:[{t:"Time Zone Converter",u:"worldclock/converter.html"},{t:"Meeting Planner",u:"worldclock/meeting.html"},{t:"Time Zone Abbreviations",u:"library/abbreviations/timezones/"},{t:"Time Zone News",u:"news/time/"},{t:"Daylight Saving Time",
u:"time/aboutdst.html"}]},{p:"/calendar/",s:[{t:"Calendar for 2010",u:"?year=2010"},{t:"Calendar for 2011",u:"?year=2011"},{t:"Monthly Calendar",u:"monthly.html"},{t:"Basic Creator",u:"basic.html"},{t:"Advanced Creator",u:"custommenu.html"}]},{p:"/",s:[{t:"Sun Calculator",u:"worldclock/sunrise.html"},{t:"Moon Calculator",u:"worldclock/moonrise.html"},{t:"Moonphases",u:"calendar/moonphases.html"},{t:"Seasons",u:"calendar/seasons.html"},{t:"Day and Night Map",u:"worldclock/sunearth.html"},{t:"Eclipses",
u:"eclipse/"}]},{p:"/",s:[{t:"Countdown to Any Date",u:"counters/customcount.html"},{t:"Date Duration",u:"date/duration.html"},{t:"New Year Countdown",u:"counters/newyear.html"},{t:"Date Calculator",u:"date/dateadd.html"},{t:"Dialing Codes",u:"worldclock/dialing.html"},{t:"Distance Calculator",u:"worldclock/distance.html"}]},{p:"/",s:[{t:"What's new?",u:"updates/"},{t:"About Us",u:"information/"},{t:"Customization",u:"custom/"},{t:"Newsletter",u:"newsletter/"},{t:"Site Search",u:"search/"},{t:"Site Map",
u:"sitemap.html"}]}];sm="_,Jan,Feb,Mar,Apr,May,Jun,Jul,Aug,Sep,Oct,Nov,Dec".split(/,/);function pf(a,c){for(;(a="0000"+a)&&a.length<c;);return a.substring(a.length-c)}function p2(a){return a<10?"0"+a:a}function lim(a,c,d){return Math.max(Math.min(a,d),c)}function dt(){return(new Date).getTime()}function gf(a){var c=document;if(c.getElementById)return c.getElementById(a);if(c.all)return c.all[a];return null}function ih(a,c){if(a)a.innerHTML=c}function iH(a,c){ih(gf(a),c)}
function sd(a,c){if(a)a.style.display=c?c==2?"block":"":"none"}function he(a,c){sd(gf(a),c)}function ee(a,c,d){if(a=a[c])a.disabled=!d}function ac(a,c,d){var e,f,g;if(a){e=a.className+" ";f=" "+e;g=f.indexOf(" "+c+" ");if(d){if(g>=0)return;e+=c}else{if(g<0)return;e=e.substring(0,g)+f.substring(g+c.length+1)}a.className=e}}function wl(a){var c=window.location;if(a)c.href=a;return c}sem_a={};
function sem(a,c){var d;d=a.name;a="e"+d;if(sem_a[d]!=c){sem_a[d]=c;a=gf(a);d=gf(d);if(a){ih(a,c);ac(a,"errmark",c)}d&&ac(d,"errf",c)}}function gx(){function a(f){try{if(d.ActiveXObject)return new ActiveXObject(f)}catch(g){}}var c=null,d=window;try{if(d.XMLHttpRequest)c=new XMLHttpRequest}catch(e){}c||(c=a("Msxml2.XMLHTTP"));c||(c=a("Microsoft.XMLHTTP"));return c}
function gp(a,c,d){if(a)try{a.open("GET","http://"+document.domain+c,true);a.onreadystatechange=d;a.send("");return 1}catch(e){alert(e)}return 0}function rs4(a){if(a&&a.readyState==4)if(a.status!==200){errm="rs4:status="+a.status;return}else return a.responseText+"";return false}function po(a){for(var c={x:0,y:a.offsetHeight};a;){c.x+=a.offsetLeft;c.y+=a.offsetTop;a=a.offsetParent}return c}function gso(a){return a.options[a.selectedIndex]}
function gfv(a){var c=a.type;if(c)switch(c){case "select-one":return gso(a).value;case "text":case "hidden":return a.value;case "radio":if(a.checked)return a.value;break;case "checkbox":return a.checked?a.value:"";case "button":case "submit":return null;default:alert("Unknown type "+c)}return null}function ga(a){var c=[],d=a.elements,e=d.length,f,g;for(f=0;f<e;f++){a=d[f];g=gfv(a);if(g!==null)c[a.name]=g}return c}
function au(a){var c=[],d=0,e;for(e in a)c[d++]=e+="="+escape(a[e]);return c.join("&")}function ap(a){for(var c=0,d=0;a;){c+=a.offsetLeft;d+=a.offsetTop;a=a.offsetParent}return{x:c,y:d}}function ep(a,c){a=a.style;a.left=c.x+"px";a.top=c.y+"px"}function es(a,c){a=a.style;a.width=c.w+"px";a.height=c.h+"px"}function jp(a,c,d,e,f){c=c.offsetWidth;var g=d.offsetWidth;d=d.offsetHeight;if(e==-1)a.x-=c-g;if(e==1)a.x+=g;if(f==-1)a.y-=d;if(f==1)a.y+=d;if(a.x<0)a.x=0}
function ru(a,c){var d,e,f=c.split("&");a=a.replace(/\?/,"?&");for(e=0;e<f.length;e++){c=f[e];d=c.indexOf("=");if(d>0){d=c.substr(0,d+1);d=a.indexOf("&"+d);if(d>0)a=a.substring(0,d+1)+c+a.substring(d+1);else a+="&"+c}}return a.replace(/\?\&/,"?")}function hu(a){return a.replace(/\&/,"&amp;")}
function siv(a){var c=document.body,d=c.scrollLeft,e=c.scrollTop,f=c.clientWidth,g=c.clientHeight,i=ap(a),j=a.clientWidth;a=a.clientHeight;var k=0,q=0;d=i.x-d;if(d<0)k=d;d+=j-f;if(d>0)k=d;d=i.y-e;if(d<0)q=d;d+=a-g;if(d>0)q=d;if(k)c.scrollLeft+=k;if(q)c.scrollTop+=q}function ael(a,c,d,e){if(a.addEventListener)a.addEventListener(c,d,e);else a.attachEvent&&a.attachEvent("on"+c,d)}function oael(a,c,d,e){var f;f=a.id;if(!f)f=a.name;if(!f)f=a.href;f=c+":"+f;if(!elh[f]){elh[f]=1;ael(a,c,d,e)}}
function PU(a){this.n=a;this.s=0}PU.prototype.h=function(a){var c=gf(this.n);this.e=c;this.s=-1;ih(c,a);sd(c,2);return c};PU.prototype.k=function(){sd(this.e,0);this.s=0;this.c&&this.c()};PU.prototype.x=function(a){a&&a!=this.s||this.s>=0&&this.k()};PU.prototype.y=function(){this.s=-1};PU.prototype.z=function(){var a=dt()+1E3,c=this;c.s=a;window.setTimeout(function(){c.x(a)},1100)};pM=new PU("po1");nM=new PU("ho");nM.c=function(){if(this.li){ac(this.li,"hovact",0);this.li=0}};
function mena(a,c){men[a]=c}function menh(a){var c,d=menact;if(d)if(c=d.e.getElementsByTagName("li")){var e=function(f,g){typeof f!="undefined"&&f>=0&&f<c.length&&ac(c[f],"h",g)};e(d.h,0);e(a,1);d.h=a}}function menc(a){var c=menact;if(c)if(a=c.a[a]){c.i.value=a.n;c.g&&a.U&&wl(a.U)}pM.k()}
function mens(a,c){var d,e,f,g,i,j,k,q,u,v,h,r,s,n,l=men[a];if(l){a=ap(c);d=l.u?l.u.replace(/\&amp\073/g,"&"):"/";e=l.a;f=0;g=l.c?l.c:"mn";i=l.C?l.C:g;g="<div class="+g+" onmouseout='pM.z()'>";j=e.length;k=l.r;q=0;u=k&&k<j;v=1;if(u){v=Math.floor((j+k-1)/k);g+="<table border=0 cellpadding=0 cellspacing=0><tr>"}else k=j;for(;v--;){q+=k;if(u)g+="<td valign=top>";for(g+="<ul class="+i+">";f<j&&f<q;f++){h=e[f];if(h.s==1)g+="<li class=mnd>&nbsp;";else{r="";if(h.p)r=hu(ru(d,h.p));if(h.u)r=h.u;s=(s=(v?"lr":
"")+(f==k-1?" ls":""))?"class='"+s+"' ":"";n="h";if(h.s)n+=" asb";g+="<li onmouseover='pM.y()'"+(h.h?" class='"+n+"' ":"")+">";n=h.n+(h.d?h.d:"");if(h.c)n="<span class="+h.c+">"+n+"</span>";if(h.s!=2)if(r)n="<a "+s+"href='"+r+"'>"+n;else if(l.i)n="<a "+s+"href='javascript:menc("+f+")'>"+n;g+=n;if(h.x)g+="<span class=mnx>"+h.x+"</span>";g+="</a>"}g+="</li>"}g+="</ul>";if(u)g+="</td>"}if(u)g+="</tr></table>";menact=l;d=pM.h(g);l.e=d;if(l.i){d.style.width="";e=d.offsetWidth;f=l.i.offsetWidth;if(e<f)d.style.width=
f+"px"}jp(a,d,c,typeof l.j!="undefined"?l.j:-1,1);ep(d,a);siv(d)}}
function ifd(a){var c,d,e,f,g,i,j,k,q,u,v,h,r,s,n,l,I,J,K,Q,L,x,R,S,C,y,M,T,E,B,z,w,N,U,O,F,m;if(a.e){c=a.f;_I=a.t;d=11;var t={i:c,a:[]};_F=c.value;A=function(p,o,G){f=o.s;f+=f?" - "+o.c:o.c;p.a[p.a.length]={c:"ash",n:o.n,x:f,U:o.i,h:0,d:o.f?"<img height=16 width=16 class=fr alt=Flag src='"+o.f+"'>":""}};D=function(){a.m=t;a.u=-1;mena(a.n,t);mens(a.n,c)};b=function(p,o){g=p.indexOf(o);if(g<0)return 0;i=o.length;if(g==0)return i;if(p.charCodeAt(g-1)<65)return i*0.9;j=o.length;if(j<2)return 0;i*=(j+
0.1)/(j+5);p=p.substr(0,g);if(k=p.match(/([\040-\077]+)/))return 0.5*i/(1+k.length);return 0.1};Y=function(){return{i:c,a:[],c:"as",C:"asu",g:1,j:0}};var H=function(p){if(p){_D=Y();a.p=p;if(_A=p.length){q=w.split(/\s+/);u=q.length;_B=[];for(e=0;e<_A;e++){h=p[e];for(v=s=r=0;v<u;v++){_H=q[v];n=" "+_H+" ";_G=(h.o==_H)*10+(h.a==_H)*5;var o=h.x.indexOf(n)>=0;if(h.t.indexOf(_H)>=0||h.e.indexOf(_H)>=0||h.u.indexOf(_H)>=0||o){l=b(h.t,_H)*10;I=b(h.e,_H)*5;J=b(h.u,_H)*4;if(o&&_G<10)_G=10+h.z;if(l>_G)_G=l;if(I>
_G)_G=I;if(J>_G)_G=J}if(_G){s++;r+=_G}}if(r>0){K=s/u;_B[_B.length]={w:s,s:(h.p*3+r)*K*K,c:h}}}_B.sort(function(G,P){return P.s-G.s});_A=_B.length;if(_A>20)_A=20;if(_A>0){Q=_A>5?5:_A;x=_B[0].s;R=x*0.7;S=x*0.2;C=1;y=0;for(e=1;e<_A;e++){L=x;x=_B[e].s;if(x<S){_A=e;break}M=L-x;if(e<Q&&M>C&&L>R){C=M;y=e}}if(y>3||C<1.2)y=0;if(y){for(e=0;e<y;e++)A(_D,_B[e].c,1);_D.a[_D.a.length]={s:1}}_B=_B.slice(y,_A);_A=_B.length;_B.sort(function(G,P){return G.c.n.localeCompare(P.c.n)});for(e=0;e<_A;e++)A(_D,_B[e].c,0)}else _D.a[0]=
{n:"No matches",s:2,h:0,c:"ash"};_D.a[_D.a.length]={u:"/worldclock/",n:"World Clock",s:100,h:1};t=_D}}};if(_I.length==1){T=_F=_F.replace(/[^\d]/g,"");E=new Date;z=2;a.i=1;if(_I=="y"){_C=E.getFullYear()-5;z=_F.length;if(z>0){if(z<4)_F+="1005".slice(z);_C=_F.slice(0,4)-5}a.a=3999;z=4}if(_I=="m"){_C=1;d=12;a.a=12;B=sm}if(_I=="d"){_C=1;d=31;a.a=31;t.r=10}_C=lim(_C,1,3989);if(_I=="i"||_I=="s"){_C=0;d=60;a.i=0;a.a=59;t.r=10}if(_I=="h"){_C=0;d=24;a.i=0;a.a=23;t.r=12;B=[];for(e=0;e<d;e++)B[e]=(e+11)%12+1+
(e<12?"am":"pm")}for(e=0;e<d;e++){E=B?" - "+B[_C]:"";t.a[t.a.length]={n:pf(_C,z),d:E,h:T==_C};_C++}}if(_I.length==2){a.l=1;if(a.o)return;else if(_I=="ci"){_F=_F.replace(/^\s+/g,"").replace(/\s+$/g,"").replace(/\s+/," ");if(!a.c)a.c={};w=_F.toLowerCase();d=a.c[w];if(w&&w.length>=2)if(d)d.d?H(d.d):H(a.p);else{d="/worldclock/wcauto.php?query="+encodeURIComponent(w);if(a.x)d+="&xd="+a.x;if(N=gx()){a.c[w]={};gp(N,d,function(){if(U=rs4(N)){O=U.split("\n");i_count=O.length;F=[];for(e=0;e<i_count;e++){m=
O[e].split("\t");if(m.length>7)F[e]={i:m[0],p:m[1],o:m[2],a:m[3],n:m[4],s:m[5],c:m[6],f:m[7],t:m[4].toLowerCase(),e:m[5].toLowerCase(),u:m[6].toLowerCase(),x:" "+m[8]+" ",z:m[9]-0}}a.c[w].d=F;H(F);D()}})}H(a.p)}else{pM.k();return}if(t.a.length==0)t.a[0]={n:"Loading...",s:2,c:"ash"}}}D()}}function ifku(a,c){return ifd(a)}function ifpd(a){a.preventDefault&&a.preventDefault();a.returnValue=false}
function ifkd(a,c){var d,e,f,g,i,j,k;j=a.f;i=true;k=(g=window.event)?g.keyCode:c.which;d=a.u;e=a.m;f=a.l&&e;g=0;if(k==27){a.e=0;pM.k()}if(k==38)g=-1;if(k==40)g=1;if(g)if(f){c=e.a.length-1;for(i=0;i<3;i++){if(d==-1){a.o=j.value;d=g>0?0:c}else d+=g;if(d>c)d=-1;if(d==-1||!e.a[d].s)break}j.value=d>=0?e.a[d].n:a.o;if(d<0)a.o=null;a.u=d;menh(d);return false}else{c=j.value-0;if(c>=0)c+=g;a=fh[j.name];if(!a||!a.a||a.i<=c&&a.a>=c){j.value=c;i=false}}else if(k==13){if(d>=0)if(f&&e.g){j=e.a[d];a.s&&wl(j.U);
ifpd(c);return false}}else a.o=null;ifd(a);return i}function ifs(a){var c=a.u;if(a.s&&c>=0)return false;return true}function ifcb(a,c,d){pM.x()}function ifc(a,c,d,e){var f=a.name,g=fh[f];if(!g){g={n:f,f:a,t:c};fh[f]=g;oael(a,"keydown",function(i){ifkd(g,i)},0);oael(a,"keyup",function(i){ifku(g,i)},0);oael(a,"blur",function(i){ifcb(a,g,i)},0);if(d){g.s=1;oael(a.form,"submit",function(i){return ifs(g)})}if(e)g.x=e}g.e=1;return ifd(g)}
function om(a,c){var d,e,f,g;d=menus[c];c=d.p;var i=d.s,j=i.length,k="";oael(a,"mouseout",function(){nM.z()},0);nM.c();nM.li=a.parentNode;ac(nM.li,"hovact",1);if(j){for(f=0;f<j;f++){g=f?f==j-1?"id=mil":"":" id=mif";d=i[f];e=(e=d.u)?c+e:c;k+="<li><a href='"+e+"' onmouseover='nM.y()'"+g+">"+d.t+"</a></li>"}c=nM.h(k);a=po(a);a.x-=2;ep(c,a);nM.y()}}blo=-1;
function blf(){var a=window,c=wl().href,d=document.title,e;if(e=a.sidebar){e.addPanel(d,c,"");return false}if(e=a.external){e.AddFavorite(c,d);return false}}function bls(a){var c=gf("FB");sd(c,blo);if(blo<0){a=a.href.replace(".h","-frame.h");ih(c,"<iframe id=FBF src='"+a+"' width=750 height=500 frameborder=0>webmaster@timeanddate.com</iframe>")}blo=!blo;return false}function blc(){blo=0;bls();blo=-1}function blw(a,c,d,e){document.write('<a href="'+a+'" alt="'+d+'"'+e+">"+c+"</a>")}
function blh(a){if(!a)a=window.event;if(a)if(a=a.target||a.srcElement){if(a.id)return blf();if(a=a.href)try{if(window.open(a,"blhw"))return false}catch(c){}}return 1}
function bli(){var a,c,d,e,f;if(c=wl()){a="?url="+c.pathname;if(c=c.search)a+=escape(c);blw("/information/feedback.html"+a,"Feedback","Send feedback to us",' onclick="return bls(this)"');a.length>8?blw("/createshort.html"+a,"Short URL","Create a short URL to this page",""):blw("/information/linkpolicy.html","Link policy","About linking","");if(c=gf("IM")){e=c.getElementsByTagName("area");f=e.length-1;a+="&title="+escape(document.title);for(d=0;d<=f;d++){c=e.item(d);c.href+=a;if(d==f)c.onclick=function(){return bls(this)};
else{c.onclick=blh;c.alt=c.title="Add this page to "+c.alt}}}}}function ott(a,c,d){oael(a,"mouseout",function(e){pM.z()});d=c;if(ttt&&ttt[c])d=ttt[c];d="<div id=ttb onmouseover='pM.y()' onmouseout='pM.z()'>"+d+"</div>";c=ap(a);d=pM.h(d);jp(c,d,a,-1,0);ep(d,c)};
