/* v.8.0.6 50d08f6bab930b77aadc58140860a36c */var liveintent=null;(function(){var ua=navigator.userAgent.toLowerCase(), d=document, b={ie6:/msie 6.0/.test(ua), opr:/opera/.test(ua), ie7:/msie 7.0/.test(ua), msi:(/msie/.test(ua))&&!(/opera/.test(ua))}, w=window, de=d.documentElement, db=d.body;liveintent={li_conf:{"offset_x":0, "offset_y":0, "win_pos":'side_left', "designs":['a', 'b'], "d_sizes":{"a":{w:300, h:293}, "b":{w:300, h:350}}}, li_exfr:false, li_exlo:false, li_mout:true, li_page:'', did:'b', li_css:function(ph){try{var l=d.ce("link");l.rel="stylesheet";l.type="text/css";l.href=ph;l.media="all";d.gn("head")[0].appendChild(l);}catch(e){}}, li_setc:function(name, value, expires){if(expires){var date=new Date();date.setTime(date.getTime()+(expires*86400000));}d.cookie=name+"="+value+((expires)?";expires="+date.toGMTString():"")+";path=/";}, li_getc:function(name){var nameEQ=name+"=", ca=d.cookie.split(';');for(var i=0;i<ca.length;i++){var c=ca[i];while(c.charAt(0)==' ')c=c.substring(1,c.length);if(c.indexOf(nameEQ)==0)return c.substring(nameEQ.length,c.length);}return false;}, li_delc:function(name){if(this.li_getc(name)){this.li_setc(name, '',-1);}}, li_getd:function(){var dc=this.li_getc('did'), ds=this.li_conf['designs'];if(dc){for(key in ds){if(ds[key]==dc){return dc;}}this.li_delc('did');return ds[0];}else{var rand=Math.floor((Math.random()*ds.length));return ds[rand];}}, li_setd:function(){if(this.did==''){var did=this.li_getd();this.li_setc('did', did, 364);this.did=did;}}, li_list:function(){var or=w.onresize;w.onresize=function(){if(or){or();};liveintent.li_pos();};var ol=w.onload;w.onload=function(){liveintent.li_adp();if(ol){ol();};};}, li_spos:function(){if(typeof(w.pageYOffset)=="number"){return [ w.pageXOffset, w.pageYOffset ];}else{if(db&&(db.scrollLeft||db.scrollTop)){return [ db.scrollLeft, db.scrollTop ];}else{if(de&&(de.scrollLeft||de.scrollTop)){return [ de.scrollLeft, de.scrollTop ];}else{return [ 0, 0 ];}}}}, li_area:function(cs){var xs=0, ys=0, ww=0, wh=0;if(cs){if(w.innerHeight&&w.scrollMaxY){xs=db.scrollWidth;ys=w.innerHeight+w.scrollMaxY;}else{if(db.scrollHeight>db.offsetHeight){xs=db.scrollWidth;ys=db.scrollHeight;}else{xs=db.offsetWidth;ys=db.offsetHeight;}}}if(self.innerHeight){ww=self.innerWidth;wh=self.innerHeight;}else{if(de&&de.clientHeight){ww=de.clientWidth;wh=de.clientHeight;}else{if(db&&(db.clientWidth||db.clientHeight)){ww=db.clientWidth;wh=db.clientHeight;}else{if(db){ww=db.clientWidth;wh=db.clientHeight;}}}}return [(cs!==true||xs<ww?ww:xs),(cs!==true||ys<wh?wh:ys)];}, li_pos:function(){var btn=d.gi('liveintent_follow_us_btn'), btnw=btn.clientWidth?btn.clientWidth:btn.offsetWidth, btnh=btn.clientHeight?btn.clientHeight:btn.offsetHeight, cnt=d.gi('liveintent_app_container'), cnts=cnt.style, cntw=cnt.clientWidth, cnth=cnt.clientHeight, ps=this.li_xy(btn), lpos=ps[0], tpos=ps[1], spos=this.li_spos(), area=this.li_area(), side=false, dt_x=0, dt_y=btnh, wpos=(this.li_conf['win_pos']!='')?this.li_conf['win_pos']:btn.getAttribute('li_window_pos')?btn.getAttribute('li_window_pos'):"left";if(wpos=='side_left'||wpos=='side_right'){side=true;dt_x=btnw;dt_y=0;}if(tpos+dt_y-spos[1]+cnth>area[1]){if(tpos>cnth){if(side){tpos-=cnth-btnh;}else{tpos-=cnth+2;}}else{tpos+=btnh+2;}}else{if(!side){tpos+=btnh+2;}}if((lpos+dt_x-spos[0]+cntw>area[0])||(wpos=='right')||(wpos=='side_right')){if(side){lpos-=cntw;if(b.ie6){lpos-=10;}}else{lpos-=cntw-btnw;}}else{if(side){lpos+=btnw;if(b.ie6){lpos-=10;}}}lpos+=this.li_conf['offset_x'];tpos+=this.li_conf['offset_y'];cnts.left=lpos+"px";cnts.top=tpos+"px";}, li_clo:function(ob){d.gi(ob).style.display='none';}, li_ope:function(ob){d.gi(ob).style.display='block';}, li_app_load:function(){this.li_clo('liveintent_app_preloader');this.li_ope('liveintent_app_place');this.li_exlo=true;}, li_psn_path:function(){return 'http://cdn.liveintent.com/exwin/gothamist/exwin_psn_v8'+this.did+this.li_page+'.html';}, li_close_app:function(){this.li_cto();this.li_psms();setTimeout('liveintent.li_clo("liveintent_app_container")', 300);}, li_show_app:function(){var btn=d.gi('liveintent_follow_us_btn'), sh=true, path=this.li_psn_path(), fr=d.gi('liveintent_app_iframe');if(d.gi('liveintent_app_container').style.display!='block'){this.li_ope('liveintent_app_container');}else{sh=false;}this.li_pos();if(!this.li_exfr){d.gi('liveintent_app_place').innerHTML='<iframe id="liveintent_app_iframe" name="liveintent_app_iframe" onload="return liveintent.li_app_load();" src="'+path+'" width="'+this.li_conf['d_sizes'][this.did].w+'px" height="'+this.li_conf['d_sizes'][this.did].h+'px" frameborder="0" scrolling="no" align="top" ALLOWTRANSPARENCY="true"></iframe>';this.li_exfr=true;}if(this.li_exlo&&sh){this.li_psms();}this.li_cto();}, li_psms:function(){var fr=d.gi('liveintent_app_iframe'), path=this.li_psn_path();fr.contentWindow.location=path+'#show';fr.height=fr.height>this.li_conf['d_sizes'][this.did].h?this.li_conf['d_sizes'][this.did].h:(this.li_conf['d_sizes'][this.did].h+1);}, li_adp:function(){this.li_cr('<img id="liveintent_pixel" width="1" height="1" alt="" src="http://l1.ly/18Q?aid=gothamist&did='+this.did+'&st=bv&ua=un&k=ex"/>', 10003);}, li_xy:function(a){var e=document.documentElement, x=0, y=0, o=0, p=0, r=/fixed/;do{o=r.test(a.style.position);p |=o;y+=a.offsetTop||0;x+=a.offsetLeft||0;if(o&&a){y+=a.scrollTop;x+=a.scrollLeft;}a=a.offsetParent;}while(a);if(!b.ie6&&e.scrollTop&&p){y+=e.scrollTop;x+=e.scrollLeft;}return [ x, y ];}, li_cr:function(html, index){var el=d.createElement("div"), es=el.style;es.position="absolute";es.zIndex=index;es.top="0";es.left="0";d.body.insertBefore(el, d.body.firstChild);el.innerHTML+=html;}, li_cto:function(){if(this.li_tmr!==null){clearTimeout(this.li_tmr);}}, li_tmr:null, li_stm:function(){this.li_tmr=setTimeout('liveintent.li_close_app()', 1700);}, li_on:function(){this.li_setd();this.li_css('http://cdn.liveintent.com/exwin/css/exwin_v8'+this.did+'.css');var i=0;if(b.opr){i_0=33554431;}else{i_0=2147483647;}this.li_cr('<div id="liveintent_app_container" onmouseout="liveintent.li_stm()" onmouseover="liveintent.li_cto()" style="display:none;overflow-y:hidden;"><div id="liveintent_close_btn" onClick="liveintent.li_close_app();"><img alt="x" src="http://cdn.liveintent.com/exwin/img/close_v8'+liveintent.did+'.gif"/></div><div id="liveintent_app_preloader"><div id="liveintent_app_loading">Loading...</div></div><div id="liveintent_app_place" style="display:none;"></div></div>', i_0);this.li_list();}};d.ce=d.createElement;d.gn=d.getElementsByTagName;d.gi=d.getElementById;liveintent.li_on();})();