if(!Array.prototype.push){Array.prototype.push=function(){var i=0,b=this.length,a=arguments;for(i;i<a.length;i++){this[b+i]=a[i];}return this.length;};}if(!Array.prototype.pop){Array.prototype.pop=function(){var b=this[this.length-1];this.length--;return b;};}if(!Array.prototype.shift){Array.prototype.shift=function(){var _3=this[0];for(var i=0;i<this.length-1;i++){this[i]=this[i+1];}this.length--;return _3;};}var _numeric_sort_func=function(a,b){return (a-b);};Number.prototype.addZeros=function(p){if((""+this).length>=p){return this;}return (new Array(p).join("0")+this).substr((new Array(p).join("0")+this).length-p);};Number.prototype.pretty_num=function(){var s=this.toString();sA=s.split(".");s1=sA[0];s2=(sA[1])?"."+sA[1]:"";if(s1.length<4){return s;}var _7="";for(var i=s1.length-1;i>-1;i--){if(i<s1.length-1&&(s1.length-1-i)%3==0){_7=","+_7;}_7=s1.charAt(i)+_7;}return _7+s2;};Number.prototype.truncate_geo_value=function(){var s=this.toString();sA=s.split(".");if(sA.length<2){return this;}d=sA[1];if(d.length<7){return this;}d=d.substring(0,6);return (sA[0]+"."+d)*1;};String.prototype.truncate_geo_value=function(){return _pf(this).truncate_geo_value();};String.prototype.pretty_num=function(){return _pf(this).pretty_num();};String.prototype.trim=function(){return this.replace(/^\s+|\s+$/g,"");};String.prototype.nl2br=function(){return this.split("\n").join("<br />\n");};String.prototype.replace=function(_8,_9){return this.split(_8).join(_9);};String.prototype.escape_for_xml=function(){return this.replace("&","&amp;").replace("\"","&quot;").replace("<","&lt;").replace(">","&gt;");};String.prototype.unescape_from_xml=function(){return this.replace("&quot;","\"").replace("&lt;","<").replace("&gt;",">").replace("&amp;","&");};String.prototype.escape_for_display=function(){return this.replace("<","&lt;");};String.prototype.escape_for_display_and_wrap=function(){return this.replace("<","<wbr>&lt;");};String.prototype.truncate_with_ellipses=function(_10){var t=this;if(t.length>_10-3){t=t.substr(0,_10-3)+"...";}return t;};document.getElementsByClass=function(_12,_13,_14){if(!_13){_13="*";}var _14=(_14)?_14:document;if(!_14.getElementsByTagName){alert(_14.id+"  has no getElementsByTagName method");}var _15=_14.getElementsByTagName(_13);var _16=new Array();var i;var j;for(var i=0,j=0;i<_15.length;i++){var c=" "+_15[i].className+" ";if(c.indexOf(" "+_12+" ")!=-1){_16[j++]=_15[i];}}return _16;};var F={id:"F",is_windows:(navigator.appVersion.toLowerCase().indexOf("mac")==-1&&navigator.appVersion.toLowerCase().indexOf("nix")==-1&&navigator.appVersion.toLowerCase().indexOf("nux")==-1),changes_count:0,_ebA:[],_decoratedO:{}};F.get_tags_from_input_str=function(str){str=str.trim();if(str==""){return [];}var _20=str.split("\"");var _21=[];for(var i=0;i<_20.length;i++){var bit=_20[i].trim();if(i%2==0){var _23=bit.split(" ");for(var k=0;k<_23.length;k++){if(_23[k]!=""){_21.push(_23[k]);}}}else{if(bit!=""){_21.push(bit);}}}return _21;};F.array_copy=function(A){var c=[];for(var i=0;i<A.length;i++){c[i]=A[i];}return c;};F.array_copy_except=function(A,_26){var c=[];for(var i=0;i<A.length;i++){if(_26==undefined||A[i]!=_26){c.push(A[i]);}}return c;};F.array_index_of=function(A,_27){for(var i=0;i<A.length;i++){if(A[i]==_27){return i;}}return -1;};F.get_dates_from_form=function(_28,_29){var _30;var _31;var _32;var _33=_ge(_28+"date_posted_exact");var _34=_ge(_28+"time_posted_exact");if(_33){var d0A=_33.value.split("/");_30=_convert_MYSQLDateTime_into_unix_time_stamp(d0A[2]+"-"+d0A[0]+"-"+d0A[1]+" "+_34.value);if(_29>0){_30=_30+_29;}}if(_ge(_28+"date_taken_exact_div").style.display=="none"){var _36=_ge(_28+"date_taken_approx_month");var _37=_ge(_28+"date_taken_approx_year");_31=_37.options[_37.selectedIndex].value;if(_36.options[_36.selectedIndex].value!=0){_32="4";_31+="-"+_36.options[_36.selectedIndex].value+"-01";}else{_32="6";_31+="-01-01";}_31+=" 00:00:00";}else{var _38=_ge(_28+"date_taken_exact");var _39=_ge(_28+"time_taken_exact");var _40=_38.value.split("/");_32="0";_31=_40[2]+"-"+_40[0]+"-"+_40[1]+" "+_39.value;if(_29>0){var _41=_convert_MYSQLDateTime_into_unix_time_stamp(_31);_41=_41+_29;_31=_convert_unix_time_stamp_into_MYSQLDateTime(_41);}}return {date_posted:_30,date_taken:_31,date_taken_granularity:_32};};F.remove_el=function(el,p,_43){if(_43){F.drag_unreg(el);}_ge_cache_remove(el);p=(p)?p:el.parentNode;p.removeChild(el);};F.drag_unreg=function(el){if(el.fumb_target){el.fumb_target.unreg();}if(el.fumb_drag){el.fumb_drag.unreg();}if(el.set_photo_drag){el.set_photo_drag.unreg();}if(el.set_photo_target){el.set_photo_target.unreg();}if(el.set_div_drag){el.set_div_drag.unreg();}if(el.set_div_target){el.set_div_target.unreg();}if(el.dot_drag){el.dot_drag.unreg();}if(el.dot_target){el.dot_target.unreg();}if(el.pinwin_thumb_drag){el.pinwin_thumb_drag.unreg();}if(el.pinwin_thumb_target){el.pinwin_thumb_target.unreg();}if(el.batch_photo_drag){el.batch_photo_drag.unreg();}if(el.batch_photo_target){el.batch_photo_target.unreg();}if(el.group_photo_drag){el.group_photo_drag.unreg();}if(el.group_photo_target){el.group_photo_target.unreg();}for(var i=el.childNodes.length-1;i>=0;i--){var ch=el.childNodes[i];F.drag_unreg(ch);}};F.decorate=function(el,obj){if(!obj){return;}if(!el){return;}if(!el.id){writeDebug("decorated els must have ids!");return;}if(typeof obj._decotype=="object"){F.decorate(el,obj._decotype);}for(p in obj){if(p=="_decotype"){continue;}el[p]=obj[p];}if(this._decoratedO[el.id]){}else{this._decoratedO[el.id]=[];}this._decoratedO[el.id].push(el);return el;};F.changes_were_made=function(){this.changes_count=1;};F.changes_were_saved=function(){this.changes_count=0;};F.make_one_photo_edit_pop=function(){var div=document.createElement("div");div.id="one_photo_edit_pop";document.body.appendChild(div);F.decorate(div,F._one_photo_edit_pop).pop_go_go_go();return div;};F.make_batch_edit_pop=function(_47,_48){var div=document.createElement("div");div.id="batch_edit_pop";document.body.appendChild(div);F.decorate(div,F._batch_edit_pop).pop_go_go_go(_47,_48);return div;};F.make_shadow=function(_49,_50,_51,_52){var _53=(_51)?_51:document.body;var div=document.createElement("div");div.id=_49+"_shadow";if(_52&&_52.parentNode==_51){_53.insertBefore(div,_52);}else{_53.appendChild(div);}F.decorate(div,F._shadow).shadow_go_go_go(_49,_50,_53);return div;};F._carrot=new Object();F._carrot.carrot_go_go_go=function(_54,_55,_56,_57){this.carrot_open_img=new Image();if(_54=="up"){this.carrot_open_img.src="/images/caret_open_up.gif";}else{this.carrot_open_img.src="/images/caret_open_down.gif";}this.carrot_closed_img=new Image();this.carrot_closed_img.src="/images/caret_closed.gif";this.carrot_is_open=(_55)?1:0;if(this.carrot_is_open){this.carrot_open_text=(_56)?_56:this.childNodes[1].innerHTML;this.carrot_closed_text=(_57)?_57:this.carrot_open_text;}else{this.carrot_closed_text=(_57)?_57:this.childNodes[1].innerHTML;this.carrot_open_text=(_56)?_56:this.carrot_closed_text;}this.style.cursor=(document.all)?"hand":"pointer";this.onclick_default=this.onclick;this.onclick=this.carrot_onclick;};F._carrot.carrot_onclick=function(e){if(this.carrot_is_open){this.carrot_close();}else{this.carrot_open();}};F._carrot.carrot_open=function(){this.onclick_default();this.carrot_is_open=1;this.childNodes[0].src=this.carrot_open_img.src;this.childNodes[1].innerHTML=this.carrot_open_text;};F._carrot.carrot_close=function(){this.onclick_default();this.carrot_is_open=0;this.childNodes[0].src=this.carrot_closed_img.src;this.childNodes[1].innerHTML=this.carrot_closed_text;};F._shadow=new Object();F._shadow.shadow_go_go_go=function(_59,_60,_61){this.shadow_use_local_coords=(_61!=document.body);this.shadow_for_id=_59;this.style.zIndex=_60;this.style.display="none";this.style.position="absolute";this.shadow_height_plus=-14;this.shadow_width_plus=-14;this.shadow_x_plus=-0;this.shadow_y_plus=-0;var _62=""+"<table class=\"shadow_table\" cellpadding=\"0\" cellspacing=\"0\" border=\"0\" style=\"padding:0px;\">"+"<tr><td width=\"11\"><img class=\"trans_png\" width=\"11\" height=\"11\" src=\"/images/tc_white_shadow_tl.png\"></td><td id=\""+this.id+"_width_controller\"><img class=\"trans_png\" width=\"100%\" height=\"11\" src=\"/images/tc_white_shadow_t.png\"></td><td width=\"11\"><img class=\"trans_png\" width=\"11\" height=\"11\" src=\"/images/tc_white_shadow_tr.png\"></td></tr>"+"<tr><td height=\"30\" id=\""+this.id+"_height_controller\"><img class=\"trans_png\" width=\"11\" height=\"100%\" src=\"/images/tc_white_shadow_l.png\"></td><td></td><td><img class=\"trans_png\" width=\"11\" height=\"100%\" src=\"/images/tc_white_shadow_r.png\"></td></tr>"+"<tr><td><img class=\"trans_png\" width=\"11\" height=\"11\" src=\"/images/tc_white_shadow_bl.png\"></td><td><img class=\"trans_png\" width=\"100%\" height=\"11\" src=\"/images/tc_white_shadow_b.png\"></td><td><img class=\"trans_png\" width=\"11\" height=\"11\" src=\"/images/tc_white_shadow_br.png\"></td></tr></table>";this.innerHTML=_62;};F._shadow.shadow_size_and_place=function(){var el=_ge(this.shadow_for_id);var x=_find_x(el,this.shadow_use_local_coords)+this.shadow_x_plus;var y=_find_y(el,this.shadow_use_local_coords)+this.shadow_y_plus;this.style.left=x+"px";this.style.top=y+"px";var w=((el.offsetWidth)+this.shadow_width_plus);if(w<0){w=0;}var h=((el.offsetHeight)+this.shadow_height_plus);if(h<0){h=0;}_ge(this.id+"_width_controller").style.width=w+"px";_ge(this.id+"_height_controller").style.height=h+"px";};F._shadow.shadow_show=function(){this.style.display="block";};F._shadow.shadow_hide=function(){this.style.display="none";};_uber_toString=function(ob,d,_69,pre){var ob=(ob)?ob:window;var d=(d)?d:1;var _69=(_69)?_69:20;var pre=(pre)?pre:(ob.id)?ob.id+".":(ob.api_key)?"params.":"root.";var _71=[];var _72="";for(var i=0;i<d;i++){_72+="\t";}if(d==1){_uber_toString._handled_Os_and_As=[ob];_71.push("{\n");}for(pr in ob){try{var _73=typeof ob[pr];if(typeof ob[pr]=="object"){_73="object";if(ob[pr]==null){_73="null";}else{if(ob[pr].length!=undefined){_73="array ("+ob[pr].length+")";}}}if(ob[pr]==_uber_toString){continue;}if(typeof ob=="object"&&ob!=null&&ob.length!=undefined&&typeof ob[pr]=="function"){continue;}_71.push(_72+pre+pr+":"+_73);if(_73=="null"){_71.push(": null\n");}else{if(typeof ob[pr]=="object"){if(ob[pr].length!=undefined){_71.push(" : [");var end="]\n";}else{_71.push(" : {");var end="}\n";}if(F.array_index_of(_uber_toString._handled_Os_and_As,ob[pr])>-1){_71.push("already been iterated over");}else{if(d>_69){_71.push(d+" is too deep ("+_69+" is max)");}else{if(pr=="F"){_71.push("F (Flickr) is not iterated over");}else{if(pr=="_decoratedO"){_71.push("_decoratedO is not iterated over");}else{if(pr=="_ebA"){_71.push("_ebA is not iterated over");}else{if(pr=="_eb_listeners"){_71.push("_eb_listeners is not iterated over");}else{if(pr=="childNodes"){_71.push("childNodes is not iterated over");}else{if(pr=="previousSibling"){_71.push("previousSibling is not iterated over");}else{if(pr=="nextSibling"){_71.push("nextSibling is not iterated over");}else{if(pr=="firstChild"){_71.push("firstChild is not iterated over");}else{if(pr=="lastChild"){_71.push("lastChild is not iterated over");}else{if(pr=="parentNode"){_71.push("parentNode is not iterated over");}else{if(pr=="offsetParent"){_71.push("offsetParent is not iterated over");}else{if(pr=="stvyle"){_71.push("style is not iterated over");}else{if(pr=="attributes"){_71.push("attributes is not iterated over");}else{if(pr=="ownerDocument"){_71.push("ownerDocument is not iterated over");}else{_uber_toString._handled_Os_and_As.push(ob[pr]);_71.push("\n"+_uber_toString(ob[pr],d+1,_69,pre+pr+".")+_72);}}}}}}}}}}}}}}}}_71.push(end);}else{if(typeof ob[pr]=="function"){_71.push(" "+ob[pr].toString().split("\n")[0].replace("function ","").replace(" {","")+"\n");}else{if(typeof ob[pr]=="string"){if(pr=="innerHTML"){_71.push(": \""+pr+"\"\n");}else{if(pr=="textContent"){_71.push(": \""+pr+"\"\n");}else{_71.push(": \""+ob[pr].replace("\"","\\\"")+"\"\n");}}}else{_71.push(": "+ob[pr]+"\n");}}}}}catch(e){writeDebug("OI! "+e.message);_71.push(_72+pre+pr+": BARF OUT "+e.message+"\n");continue;}}if(d==1){_71.push("}\n");}return _71.join("");};var global_photos={};var global_sets={};var global_groups={};var _get_photo_src=function(p,s){var str="";if(!p||!p.src){return str;}if(!s){s="s";}var src=p.src;if(s!="s"){src=src.replace("_s","_"+s);}str=_img_root+src;if(p.src_cb){str+="?"+p.src_cb;}return str;};var _upsert_photo=function(_76){var id=_76.getAttribute("id");var _78=_76.getAttribute("server");var src=_78+"/"+id+"_"+_76.getAttribute("secret")+"_s.jpg";var _79=_76.getElementsByTagName("title");if(_79&&_79[0]){var _80=_79[0];var _81=(_80.firstChild)?_80.firstChild.nodeValue:"";var _82=_76.getElementsByTagName("description")[0];var _83=(_82.firstChild)?_82.firstChild.nodeValue:"";var _84=_76.getAttribute("license");var _85=_76.getAttribute("isfavorite");var _86=_76.getElementsByTagName("visibility")[0];var _87=_86.getAttribute("ispublic");var _88=_86.getAttribute("isfriend");var _89=_86.getAttribute("isfamily");var _90=_76.getElementsByTagName("geoperms");if(_90&&_90[0]){var _91=_90[0].getAttribute("ispublic");var _92=_90[0].getAttribute("isfriend");var _93=_90[0].getAttribute("isfamily");var _94=_90[0].getAttribute("iscontact");}var _95=_76.getElementsByTagName("dates")[0];var _96=_95.getAttribute("taken");var _97=_95.getAttribute("takengranularity");var _98=_95.getAttribute("posted");var _99=_95.getAttribute("lastupdate");var _100=_76.getElementsByTagName("owner")[0];var _101=_100.getAttribute("nsid");var _102=_100.getAttribute("username");var _103=null;var _104=_76.getElementsByTagName("location");if(_104&&_104[0]){var _105=_104[0].getAttribute("latitude");var _106=_104[0].getAttribute("longitude");var _107=_104[0].getAttribute("accuracy");}var _108=_76.getElementsByTagName("permissions");if(_108&&_108[0]){var _109=_108[0].getAttribute("permcomment");var _110=_108[0].getAttribute("permaddmeta");}var _108=_76.getElementsByTagName("permissions");if(_108&&_108[0]){var _109=_108[0].getAttribute("permcomment");var _110=_108[0].getAttribute("permaddmeta");}var tags=_76.getElementsByTagName("tag");_rebuild_tags_for_photos(id,tags);var sets=_76.getElementsByTagName("set");var _113=_76.getElementsByTagName("pool");}else{var _81=_76.getAttribute("title");var _96=_76.getAttribute("datetaken");var _98=_76.getAttribute("dateupload");var _105=_76.getAttribute("latitude");var _106=_76.getAttribute("longitude");var _107=_76.getAttribute("accuracy");var _101=_76.getAttribute("owner");var _102=_76.getAttribute("ownername");var _103=_76.getAttribute("iconserver");}var p=global_photos[id];if(!p){p=global_photos[id]={id:id,title:_81,src:src};}else{p.id=id;p.title=_81;p.src=src;}p.server=_78;p.toString=function(ob,d){var ob=(ob)?ob:this;var d=(d)?d:1;var str="";var tabs="";for(var i=0;i<d;i++){tabs+="\t";}if(d==1){str+="global_photos["+p.id+"] = {\n";}for(pr in ob){if(typeof ob[pr]=="function"){continue;}str+=tabs+pr;if(typeof ob[pr]=="object"){if(ob[pr].length!=undefined){str+=" = [\n";str+=p.toString(ob[pr],d+1);str+=tabs+"]\n";}else{str+=" = {\n";str+=p.toString(ob[pr],d+1);str+=tabs+"}\n";}}else{if(typeof ob[pr]=="function"){str+=": function\n";}else{if(typeof ob[pr]=="string"){str+=": \""+ob[pr]+"\"\n";}else{str+=": "+ob[pr]+"\n";}}}}if(d==1){str+="}\n";}return str;};if(_84&&_84!=""){p.license_id=_84;}if(_84&&_84!=""){p.is_favorite=_85;}if(_96&&_96!=""){p.date_taken=_96;}if(_97!=undefined&&_97!=""){p.date_taken_granularity=_97;}if(_98&&_98!=""){p.date_upload=_98;}if(_99&&_99!=""){p.date_update=_99;}if(_105!=undefined&&_105!=""){p.latitude=_105;}if(_106!=undefined&&_106!=""){p.longitude=_106;}if(_107!=undefined&&_107!=""){p.accuracy=_107;}if(_83!=undefined){p.description=_83;}if(_87!=undefined){p.is_public=_87;}if(_88!=undefined){p.is_friend=_88;}if(_89!=undefined){p.is_family=_89;}if(_91!=undefined){p.geo_is_public=_91;}if(_92!=undefined){p.geo_is_friend=_92;}if(_93!=undefined){p.geo_is_family=_93;}if(_94!=undefined){p.geo_is_contact=_94;}if(_109!=undefined){p.perm_comment=_109;}if(_110!=undefined){p.perm_addmeta=_110;}if(_101!=undefined){p.owner_nsid=_101;}if(_102!=undefined){p.owner_name=_102;}if(_103!=undefined){p.owner_iconserver=_103;}if(sets&&sets.length){p.sets=[];for(var i=0;i<sets.length;i++){p.sets.push(sets[i].getAttribute("id"));}}if(_113&&_113.length){p.pools=[];for(var i=0;i<_113.length;i++){p.pools.push(_113[i].getAttribute("id"));}}return p;};var _upsert_set=function(node){var id=node.getAttribute("id");var _116=node.getAttribute("primary");var _117=node.getAttribute("server");var _118=node.getAttribute("secret");var _119=node.getAttribute("id");var _120=node.getAttribute("photos");var _121=node.getElementsByTagName("photo");if(_116&&_116!=""){var p=global_photos[_116];if(!p){p=global_photos[_116]={};p.id=_116;}if(_117&&_117!=""&&_118&&_118!=""){p.src=_117+"/"+p.id+"_"+_118+"_s.jpg";}}var _122=node.getElementsByTagName("title");if(_122&&_122[0]&&_122[0].firstChild){var _123=_122[0].firstChild.nodeValue;}else{var _123=node.getAttribute("title");}var _124=node.getElementsByTagName("description");if(_124&&_124[0]){if(_124[0].firstChild){var _125=_124[0].firstChild.nodeValue;}else{var _125="";}}var s=global_sets[id];if(!s){s=global_sets[id]={id:id,primary_photo_id:_116,photo_idsA:[]};}else{s.id=id;s.primary_photo_id=_116;}if(_119&&_119!=""){s.owner=_119;}if(_123&&_123!=""){s.title=_123;}if(_125!=undefined){s.description=_125;}var _121=node.getElementsByTagName("photo");if(_121&&_121.length){s.count=_121.length;s.photo_idsA=[];for(var i=0;i<_121.length;i++){var p=_upsert_photo(_121[i]);s.photo_idsA.push(p.id);}}else{if(_120!=""){s.count=_120;}}return s;};var global_reg_photo_print_ids=[1,2,3];var global_dig_photo_print_ids=[29,30,31];var global_huge_photo_print_ids=[18];var global_square_photo_print_ids=[23];var global_wallet_photo_print_ids=[32];var writeDebug=function(){};var writeAPIDebug=function(){};var timer=function(){};timer.prototype.add=function(){};timer.prototype.add_child=function(){};timer.prototype.clear=function(){};timer.prototype.get_text=function(){};timer.prototype.dump=function(){};var _page_timer=new timer("page","start");var _pi=function(str){return parseInt(str,10);};var _pf=function(str){return parseFloat(str);};_ge_cache_obj={};_ge_cache_retrieve=function(id){return _ge_cache_obj[id];};_ge_cache_add=function(el){_ge_cache_obj[el.id]=el;};_ge_cache_remove=function(el){if(!el){return;}if(el.id&&_ge_cache_obj[el.id]){_ge_cache_obj[el.id]=null;delete _ge_cache_obj[el.id];}for(var i=el.childNodes.length-1;i>-1;i--){_ge_cache_remove(el.childNodes[i]);}};var _ge=function(id){el=document.getElementById(id);return el;};var _ok_for_swf=function(){if(actualVersion<6){return false;}return true;var ua=navigator.userAgent;if(navigator.appVersion.toLowerCase().indexOf("mac")>0){if(ua.indexOf("Gecko")==-1){return false;}}else{if(ua.indexOf("MSIE 5.6")>0||ua.indexOf("MSIE 5.5")>0||ua.indexOf("MSIE 6")>0||ua.indexOf("MSIE 7")>0){}else{if(ua.indexOf("Gecko")==-1){return false;}}}return true;};var _ok_for_scrumjax_xml=function(){if(global_fakeOperaXMLHttpRequestSupport){return false;}return _ok_for_scrumjax();};var _ok_for_scrumjax=function(){if(!window.XMLHttpRequest){return false;}if(navigator.appVersion.toLowerCase().indexOf("mac")>0&&navigator.userAgent.indexOf("MSIE")>0&&navigator.userAgent.indexOf("Opera")==-1){return false;}return true;};var global_today=new Date();var global_tm=global_today.getMonth()+1;var global_td=global_today.getDate();var global_ty=global_today.getFullYear();var global_days_in_months=[31,0,31,30,31,30,31,31,30,31,30,31];var global_mn=["JAN","FEB","MAR","APR","MAY","JUN","JUL","AUG","SEP","OCT","NOV","DEC"];var global_mn_name=["January","February","March","April","May","June","July","August","September","October","November","December"];var _get_month_index=function(m){var cm=m.substr(0,3).toUpperCase();for(var i=0;i<global_mn.length;i++){if(cm==global_mn[i]){return i;}}return -1;};_make_unix_time_stamp=function(_129,_130,_131,inHr,_133,_134){var _135=new Date(_129,_130-1,_131,inHr,_133,_134);return _135.getTime()/1000;};_convert_unix_time_stamp=function(_136){return new Date(_136*1000);};_convert_unix_time_stamp_into_MYSQLDateTime=function(_137){var ld=new Date((_137*1000));return _make_MYSQLDateTime_stamp(ld.getFullYear(),(ld.getMonth()+1).addZeros(2),ld.getDate().addZeros(2),ld.getHours().addZeros(2),ld.getMinutes().addZeros(2),ld.getSeconds().addZeros(2));};_make_MYSQLDateTime_stamp=function(_139,_140,_141,inHr,_142,_143){var txt="";if(_139!=undefined){txt+=_139;}else{return txt;}if(_140!=undefined){txt+="-"+_140;}else{return txt;}if(_141!=undefined){txt+="-"+_141;}else{return txt;}if(inHr!=undefined){txt+=" "+inHr;}else{return txt;}if(_142!=undefined){txt+=":"+_142;}else{return txt;}if(_143!=undefined){txt+=":"+_143;}else{return txt;}return txt;};_convert_MYSQLDateTime_into_unix_time_stamp=function(_145){var _146=_convert_MYSQLDateTime(_145);return Math.floor(_146.getTime()/1000);};_convert_MYSQLDateTime=function(_147){var both=_147.split(" ");var cal=both[0].split("-");var tim=both[1].split(":");return new Date(cal[0],(cal[1]*1)-1,cal[2],tim[0],tim[1],tim[2]);};var _in_array=function(_151,_152){for(var i=_152.length-1;i>-1;i--){if(_152[i]==_151){return true;}}return false;};var _disable_select=function(){document.onselectstart=new Function("return false");};var _enable_select=function(){document.onselectstart=new Function("return true");};var _limit_textarea=function(_153,max){if(_153.value.length>max){_153.value=_153.value.substring(0,max);}};var _el_is_in_a_link=function(el){var p=el;while(p){if(p.href){return 1;}p=p.parentNode;}return 0;};var _get_event_src=function(e){if(e&&e.target){return e.target;}if(e&&e.srcElement){return e.srcElement;}if(window.event){return window.event.srcElement;}return null;};var _get_event_keycode=function(e){if(e){return e.keyCode;}if(window.event){return window.event.keyCode;}return null;};var _keys={TAB:9,ENTER:13,RIGHTARROW:39,DOWNARROW:40,UPARROW:38,BACKSPACE:8,CTRL:17,ESCAPE:27};var _hitch=function(obj,meth){return function(){return obj[meth].apply(obj,arguments);};};var _find_x=function(el,_156){if(_156){if(el.style.left){return _pi(el.style.left);}return el.offsetLeft;}var _157=0;if(el.offsetParent){while(el.offsetParent){_157+=el.offsetLeft;el=el.offsetParent;}}else{if(el.x){_157+=el.x;}}return _157;};var _find_y=function(el,_158){if(_158){if(el.style.top){return _pi(el.style.top);}return el.offsetTop;}var _159=0;if(el.offsetParent){while(el.offsetParent){_159+=el.offsetTop;el=el.offsetParent;}}else{if(el.y){_159+=el.y;}}return _159;};myPos={getPos:function(el){return [this.getX(el),this.getY(el)];return [_find_x(el,1),_find_y(el,1)];},getY:function(el){return _find_y(el);return _find_y(el,1);},getX:function(el){return _find_x(el);return _find_x(el,1);}};var _find_screen_height=function(){if(window.innerHeight){return window.innerHeight;}else{if(document.documentElement.clientHeight){return document.documentElement.clientHeight;}else{if(document.body.clientHeight){return document.body.clientHeight;}}}};var _find_screen_width=function(){if(window.innerWidth){return window.innerWidth;}else{if(document.documentElement.clientWidth){return document.documentElement.clientWidth;}else{if(document.body.clientWidth){return document.body.clientWidth;}}}};var _decorate=function(){var el=arguments[0];if(!el){return;}arguments[0]=el;var _160="decorate_"+el.className;if(window[_160]){return window[_160](arguments);}writeDebug(_160+" is not a function");};var _pretty_list=function(list){if(list.length==1){return list[0];}else{if(list.length==2){return list.join(" and ");}else{var last=list.pop();return list.join(", ")+" and "+last;}}};var _hyperlink=function(txt){if(txt.indexOf("http://")>-1){var txtA=txt.split("\n");for(var y=0;y<txtA.length;y++){var _164=txtA[y].split(" ");for(var t=0;t<_164.length;t++){var _165="";if(_164[t].substr(0,1)=="("){_164[t]=_164[t].replace("(","");_165="(";}if(_164[t].substr(0,7)=="http://"){var url=_164[t];var _167="";if(url.substr(url.length-1,1)==")"){url=url.substr(0,url.length-1);_167=")";}var _168="";if(url.substr(url.length-1,1)=="."){url=url.substr(0,url.length-1);_168=".";}_164[t]="<a href=\""+url+"\" onclick=\"\">"+url+"</a>"+_167+_168;}_164[t]=_165+_164[t];}txtA[y]=_164.join(" ");}txt=txtA.join("<br />");}return txt;};var global_js_tip_count=0;var _get_tip_html=function(txt,_169){if(txt.length==0){return "";}global_js_tip_count++;_169=(_169==undefined)?"Tip":_169;var _170="<span style=\"display: none;\" id=\"js_tooltip_"+global_js_tip_count+"\">"+txt+"</span>"+"<span class=\""+_169+"\">[<a href=\"#\" onclick=\"this.blur(); show_tooltip(this, 'js_tooltip_"+global_js_tip_count+"', "+txt.length+"); return false;\">?</a>]</span>";return _170;};var _set_cookie=function(name,_172,days){var _174="";if(days){var date=new Date();date.setTime(date.getTime()+(days*24*60*60*1000));_174="; expires="+date.toGMTString();}var str=name+"="+_172+_174+"; path=/";document.cookie=str;};var _get_cookie=function(name){var _176=name+"=";var ca=document.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(_176)==0){return c.substring(_176.length,c.length);}}return null;};var _delete_cookie=function(name){_set_cookie(name,"",-1);};var _rebuild_tags_for_photos=function(_178,tags){if(global_photos[_178]==undefined){return;}global_photos[_178].tagsA=[];global_photos[_178].tags_rawA=[];global_photos[_178].tags_idA=[];global_photos[_178].tags_canDeleteA=[];for(var t=0;t<tags.length;t++){var node=tags[t];var tag=node.firstChild.nodeValue;var _180=node.getAttribute("raw");var _181=node.getAttribute("id");var _182=node.getAttribute("author");var _183=(global_photos[_178].isOwner||global_nsid==_182)?true:false;global_photos[_178].tagsA.push(tag);global_photos[_178].tags_rawA.push(_180);global_photos[_178].tags_idA.push(_181);global_photos[_178].tags_canDeleteA.push(_183);}};var global_single_shadow_div;var _make_single_shadow=function(div,_184,_185,_186,_187){if(div==undefined){div=document.createElement("div");div.style.position="absolute";div.style.top="0px";div.style.left="0px";document.body.appendChild(div);}window.global_single_shadow_height_plus=(_184==undefined)?(12-24):_184;window.global_single_shadow_width_plus=(_185==undefined)?(12-24):_185;window.global_single_shadow_x_plus=(_186==undefined)?(-3):_186;window.global_single_shadow_y_plus=(_187==undefined)?(-3):_187;var html="";html+="<table class=\"shadow_table\" cellpadding=\"0\" cellspacing=\"0\" border=\"0\" style=\"padding:0px;\">";html+="<tr><td width=\"11\"><img class=\"trans_png\" width=\"11\" height=\"11\" src=\"/images/tc_white_shadow_tl.png\"></td><td id=\"shadow_width_controller\"><img class=\"trans_png\" width=\"100%\" height=\"11\" src=\"/images/tc_white_shadow_t.png\"></td><td width=\"11\"><img class=\"trans_png\" width=\"11\" height=\"11\" src=\"/images/tc_white_shadow_tr.png\"></td></tr>";html+="<tr><td height=\"30\" id=\"shadow_height_controller\"><img class=\"trans_png\" width=\"11\" height=\"100%\" src=\"/images/tc_white_shadow_l.png\"></td><td></td><td><img class=\"trans_png\" width=\"11\" height=\"100%\" src=\"/images/tc_white_shadow_r.png\"></td></tr>";html+="<tr><td><img class=\"trans_png\" width=\"11\" height=\"11\" src=\"/images/tc_white_shadow_bl.png\"></td><td><img class=\"trans_png\" width=\"100%\" height=\"11\" src=\"/images/tc_white_shadow_b.png\"></td><td><img class=\"trans_png\" width=\"11\" height=\"11\" src=\"/images/tc_white_shadow_br.png\"></td></tr></table>";div.innerHTML=html;div.style.zIndex="999";div.style.display="none";div.id="shadow_div";window._set_single_shadow_x=function(_189){div.style.marginLeft=(_189+global_single_shadow_x_plus)+"px";};window._set_single_shadow_y=function(_190){div.style.marginTop=(_190+global_single_shadow_y_plus)+"px";};window._set_single_shadow_height=function(_191){var el=_ge("shadow_height_controller");if(!el){return;}var d=((_191.offsetHeight)+global_single_shadow_height_plus);if(d<0){d=0;}el.style.height=d+"px";};window._set_single_shadow_width=function(_192){var el=_ge("shadow_width_controller");if(!el){return;}var d=((_192.offsetWidth)+global_single_shadow_width_plus);if(d<0){d=0;}el.style.width=d+"px";};window.global_single_shadow_div=div;};var global_comm_div;var _make_comm_div=function(_193){var div=_ge("comm_div");if(!div){div=document.createElement("DIV");div.id="comm_div";div.style.left=0;div.style.top=0;document.body.appendChild(div);div.modal_blocker=document.createElement("DIV");div.modal_blocker.id="modal_blocker";div.modal_blocker.style.position="absolute";div.modal_blocker.style.top=0;div.modal_blocker.default_style={};div.modal_blocker.style.backgroundColor=div.modal_blocker.default_style.backgroundColor="#999";div.modal_blocker.style.opacity=div.modal_blocker.default_style.opacity=".5";div.modal_blocker.style.filter=div.modal_blocker.default_style.filter="alpha(opacity=50)";document.body.appendChild(div.modal_blocker);}var html=""+"<table id=\"comm_table\" cellpadding=\"0\" cellspacing=\"0\" border=\"0\" style=\"width:200px; padding:0px;\">"+"<tr>"+"<td width=\"3\"><img width=\"3\" height=\"3\" src=\"/images/tc_white_tl.gif\"></td>"+"<td class=\"td_white\"></td>"+"<td class=\"td_white\"></td>"+"<td width=\"3\"><img width=\"3\" height=\"3\" src=\"/images/tc_white_tr.gif\"></td>"+"</tr>"+"<tr>"+"<td class=\"td_white\"></td>"+"<td class=\"td_white\" style=\"padding:3px 0px 0px 0px\" width=\"1\" valign=\"top\"><img id=\"comm_pulser_img\" src=\"/images/pulser2.gif\" width=\"32\" height=\"15\" border=\"0\"></td>"+"<td class=\"td_white\" style=\"padding:3px; font-family:arial; font-size:12px;\" id=\"comm_td\">"+"<div id=\"comm_msg_div\"></div>"+"<div id=\"comm_form_div\" style=\"display:none;\"></div>"+"<div id=\"comm_progress_bar_div_wrapper\" style=\"display:none; border:1px solid black; margin-top:10px;\">"+"<div id=\"comm_progress_bar_div_inner\" style=\"width:300px; height:15px\">"+"<div id=\"comm_progress_bar_div\" style=\"height:100%; width:0%; background-color:#FF0084\"></div>"+"</div>"+"</div>"+"</td>"+"<td class=\"td_white\"></td>"+"</tr>"+"<tr id=\"comm_button_tr\">"+"<td class=\"td_white\"></td>"+"<td class=\"td_white\"></td>"+"<td class=\"td_white\" style=\"padding:3px\">"+"<form>"+"<nobr><input id=\"comm_button_ok\" type=\"button\" class=\"Butt\" value=\"OK\" onclick=\"this.onclick_func();\" style=\"margin:5px 5px 0 0;\">"+"<input id=\"comm_button_cancel\" type=\"button\" class=\"CancelButt\" value=\"CANCEL\" onclick=\"this.onclick_func();\" style=\"margin:5px 5px 0 0;\"></nobr>"+"</form>"+"</td>"+"<td class=\"td_white\"></td>"+"</tr>"+"<tr>"+"<td><img width=\"3\" height=\"3\" src=\"/images/tc_white_bl.gif\"></td>"+"<td class=\"td_white\"></td>"+"<td class=\"td_white\"></td>"+"<td><img width=\"3\" height=\"3\" src=\"/images/tc_white_br.gif\"></td>"+"</tr>"+"</table>";div.innerHTML=html;div.button_tr=_ge("comm_button_tr");div.pulser_img=_ge("comm_pulser_img");div.button_ok=_ge("comm_button_ok");div.button_cancel=_ge("comm_button_cancel");div.button_ok.onclick_func=function(){div.stop_comming();this.blur();if(typeof this.onclick_plus=="function"){this.onclick_plus();}if(typeof this.onclick_do=="function"){this.onclick_do();}};div.button_cancel.onclick_func=function(){div.stop_comming();this.blur();if(typeof this.onclick_plus=="function"){this.onclick_plus();}if(typeof this.onclick_do=="function"){this.onclick_do();}};div.table=_ge("comm_table");div.comm_msg_div=_ge("comm_msg_div");div.comm_form_div=_ge("comm_form_div");div.comm_progress_bar_div_wrapper=_ge("comm_progress_bar_div_wrapper");div.style.zIndex=_193;div.style.display="none";if(div.modal_blocker){div.modal_blocker.style.zIndex=998;div.modal_blocker.style.display="none";}div.stop_comming=function(){if(this.modal_blocker){div.modal_blocker.style.zIndex=998;this.modal_blocker.style.display="none";}this.style.display="none";global_single_shadow_div.style.display="none";div.comm_form_div.style.display="none";div.comm_progress_bar_div_wrapper.style.display="none";_ge("comm_progress_bar_div").style.width=0;this.comming=0;};div.change_comming_msg=function(msg,perc,_196,_197){if(!msg){return;}this.comm_msg_div.innerHTML=msg;var w=Math.ceil(perc*_ge("comm_progress_bar_div_inner").offsetWidth);anim_do_width_to(_ge("comm_progress_bar_div"),8,30,w,"linearTween",_196,_197);_set_single_shadow_height(this.table);_set_single_shadow_width(this.table);};div.get_rid_of_form=function(){if(!div.comm_form_div.childNodes[0]){return;}var _198=div.comm_form_div.childNodes[0];_198.style.display="none";if(_198.old_parentNode){_198.old_parentNode.appendChild(_198);}else{F.remove_el(_198,div.comm_form_div);}div.comm_form_div.style.display="none";};div.start_comming=function(msg,_199,_200,_201,_202,_203,_204,_205,_206,_207,_208,_209,_210){var txt=(!msg)?"working...":msg;this.comm_msg_div.innerHTML=txt;div.comm_form_div.style.display="none";if(_208){div.get_rid_of_form();div.comm_form_div.style.display="block";_208.style.display="block";if(_208.old_parentNode!=div.comm_form_div){_208.old_parentNode=_208.parentNode;}div.comm_form_div.appendChild(_208);}div.comm_progress_bar_div_wrapper.style.display="none";if(_210){div.comm_progress_bar_div_wrapper.style.display="block";}this.pulser_img.style.display=(_201)?"none":"inline";if(_202||_205){this.button_tr.style.display=(document.all&&!window.opera)?"block":"table-row";this.button_ok.value=(_203)?_203.toUpperCase():"OK";this.button_tr.style.display=(document.all&&!window.opera)?"block":"table-row";this.button_ok.onclick_do=(typeof _204=="function")?_204:null;this.button_ok.style.visibility=(_202)?"visible":"hidden";this.button_ok.style.display=(_202)?"inline":"none";this.button_cancel.value=(_206)?_206.toUpperCase():"CANCEL";this.button_cancel.onclick_do=(typeof _207=="function")?_207:null;this.button_cancel.style.visibility=(_205)?"visible":"hidden";this.button_tr.style.display=(document.all&&!window.opera)?"block":"table-row";_ge("comm_table").style.width="312px";}else{this.button_tr.style.display="none";_ge("comm_table").style.width="200px";}this.style.display="block";if(_209&&this.modal_blocker){this.modal_blocker.style.display="block";this.modal_blocker.style.backgroundColor=(_209.backgroundColor)?_209.backgroundColor:div.modal_blocker.default_style.backgroundColor;this.modal_blocker.style.opacity=(_209.opacity)?_209.opacity:div.modal_blocker.default_style.opacity;this.modal_blocker.style.filter=(_209.filter)?_209.filter:div.modal_blocker.default_style.filter;}if(window.innerWidth){var ww=window.innerWidth;var wh=window.innerHeight;var bgX=window.pageXOffset;var bgY=window.pageYOffset;}else{var ww=document.body.clientWidth;var wh=document.body.clientHeight;var bgX=document.body.scrollLeft;var bgY=document.body.scrollTop;}var _215=function(){var x=bgX+_pi((ww-_pi(global_comm_div.table.offsetWidth))/2);return x;};var _216=function(){var y=bgY+_pi((wh-global_comm_div.table.offsetHeight)/2);return y;};var x=(typeof _199=="function")?_199():(typeof _199=="number")?_199:_215();var y=(typeof _200=="function")?_200():(typeof _200=="number")?_200:_216();this.style.marginLeft=x+"px";this.style.marginTop=y+"px";if(_209&&this.modal_blocker){if(_209.loc_style){this.modal_blocker.style.top=_209.loc_style.top+"px";this.modal_blocker.style.left=_209.loc_style.left+"px";this.modal_blocker.style.width=_209.loc_style.width+"px";this.modal_blocker.style.height=_209.loc_style.height+"px";}else{this.modal_blocker.style.top=bgY+"px";this.modal_blocker.style.left=bgX+"px";this.modal_blocker.style.width=ww+"px";this.modal_blocker.style.height=wh+"px";}}_set_single_shadow_x(x);_set_single_shadow_y(y);_set_single_shadow_height(this.table);_set_single_shadow_width(this.table);global_single_shadow_div.style.display="block";if(_202&&navigator.userAgent.indexOf("KHTML")==-1){this.button_ok.focus();}this.comming=1;};window.global_comm_div=div;if(!global_single_shadow_div){_make_single_shadow(_ge("shadow_div"));}return global_comm_div;};F._eb=new Object();F._eb.eb_go_go_go=function(){this._eb_listeners=[];F._ebA.push(this);};JS_is_wonderful_as_AS=false;F._eb.eb_broadcast=function(){if(JS_is_wonderful_as_AS){var _217=arguments.shift();}else{var _218=[];for(var i=0;i<arguments.length;i++){_218[i]=arguments[i];}var _217=_218.shift();}var list=F.array_copy(this._eb_listeners);var max=list.length;for(var i=0;i<max;++i){if(list[i][_217]){list[i][_217].apply(list[i],_218);}else{}}};F._eb.eb_add=function(obj){this.eb_remove(obj);this._eb_listeners.push(obj);return (true);};F._eb.eb_remove=function(obj){var list=this._eb_listeners;var i=list.length;while(i--){if(list[i]==obj){list.splice(i,1);return (true);}}return (false);};F._eb.eb_remove_all=function(){this._eb_listeners=[];};F.decorate(F,F._eb).eb_go_go_go();window.onresize=function(){F.eb_broadcast("window_onresize");};window.onbeforeunload=function(){F.eb_broadcast("window_onbeforeunload",F.changes_count);if(F.changes_count){return "You have unsaved changes.";}};window.onblur=function(){window.blurred=1;};window.onfocus=function(){window.blurred=0;};window.onunload=function(){F.eb_broadcast("window_unload");_ge_cache_obj={};for(var i=F._ebA.length-1;i>=0;i--){var eb=F._ebA[i];eb.eb_remove_all();}F._ebA=[];F._decoratedO={};};function _change_privacy(id){var _220=_ge("is_private_"+id).checked;_ge("is_friend_"+id).disabled=!_220;_ge("is_family_"+id).disabled=!_220;}function _get_qs_args(){var args={};var _222=location.search.substring(1).split("&");for(var i=0;i<_222.length;i++){var p=_222[i].indexOf("=");if(p!=-1){var name=_222[i].substring(0,p);var _223=_222[i].substring(p+1);args[name]=unescape(_223);}}return args;}var _qs_args=_get_qs_args();var promos_show=function(_224){var _225=_ge(_224);var _226=_ge(_224+"_promo_div");var _227=_ge(_224+"_removed_div");if(!_226){return;}var _228={};if(_224=="promo_do_more"){_228["promos_hide_do_more"]=0;}else{if(_224=="promo_reupgrade"){_228["promos_hide_reupgrade"]=0;}else{if(_224=="promo_proexpire"){_228["promos_hide_proexpire"]=0;}else{if(_224=="promo_intro"){_228["promos_hide_intro"]=0;}else{return false;}}}}_226.flickr_prefs_setPrefs_onLoad=function(){};F.API.callMethod("flickr.prefs.setPrefs",_228,_226);_226.style.visibility="visible";_227.style.display="none";};var promos_remove=function(_229){var _230=_ge(_229);var _231=_ge(_229+"_promo_div");var _232=_ge(_229+"_removed_div");if(!_231){return;}var _233={};if(_229=="promo_do_more"){_233["promos_hide_do_more"]=1;}else{if(_229=="promo_reupgrade"){_233["promos_hide_reupgrade"]=1;}else{if(_229=="promo_proexpire"){_233["promos_hide_proexpire"]=1;}else{if(_229=="promo_intro"){_233["promos_hide_intro"]=1;}else{return false;}}}}_231.flickr_prefs_setPrefs_onLoad=function(){};F.API.callMethod("flickr.prefs.setPrefs",_233,_231);_231.style.visibility="hidden";_232.style.display="block";_230.style.backgroundColor="#FFFFFF";setTimeout("anim_do_pink_fade(_ge(\""+_230.id+"\"))",300);};function _privacy_specific_change(_234,_235){_234=(_234)?_234:"";var _236=_ge(_234+"is_private").checked;var _237=_ge(_234+"is_friend").checked;var _238=_ge(_234+"is_family").checked;var _239=!_236;_ge(_234+"is_friend").disabled=!_236;_ge(_234+"is_family").disabled=!_236;_ge(_234+"is_friend_label").style.color=_236?"black":"silver";_ge(_234+"is_family_label").style.color=_236?"black":"silver";if(_236){if(_237||_238){_privacy_check_boxes(_234+"perm_comment",false,false,true,true);_privacy_check_boxes(_234+"perm_addmeta",false,false,true,true);}else{_privacy_check_boxes(_234+"perm_comment",false,true,true,true);_privacy_check_boxes(_234+"perm_addmeta",false,true,true,true);}}else{_privacy_check_boxes(_234+"perm_comment",false,false,false,false);_privacy_check_boxes(_234+"perm_addmeta",false,false,false,false);}if(!_235&&(previous_public!=_239||previous_friend!=_237||previous_family!=_238)){_privacy_try_and_check(_234+"perm_comment",1);_privacy_try_and_check(_234+"perm_addmeta",2);previous_public=_239;previous_friend=_237;previous_family=_238;}}function _privacy_default_change(){var _240=_ge("is_private").checked;var _241=_ge("is_friend").checked;var _242=_ge("is_family").checked;var _243=!_240;_ge("is_friend").disabled=!_240;_ge("is_family").disabled=!_240;_ge("is_friend_label").style.color=_240?"black":"silver";_ge("is_family_label").style.color=_240?"black":"silver";_ge("perm_addmeta_disclaim").style.display=_240?"block":"none";_ge("perm_comment_disclaim").style.display=_240?"block":"none";if(_240){if(_241||_242){_privacy_check_boxes("perm_comment",false,false,false,false);_privacy_check_boxes("perm_addmeta",false,false,false,false);}else{_privacy_check_boxes("perm_comment",false,false,false,false);_privacy_check_boxes("perm_addmeta",false,false,false,false);}}else{_privacy_check_boxes("perm_comment",false,false,false,false);_privacy_check_boxes("perm_addmeta",false,false,false,false);}}function _privacy_check_boxes(name,a,b,c,d){_ge(name+"_4").disabled=a;_ge(name+"_3").disabled=b;_ge(name+"_2").disabled=c;_ge(name+"_1").disabled=d;_ge(name+"_4_label").style.color=a?"silver":"black";_ge(name+"_3_label").style.color=b?"silver":"black";_ge(name+"_2_label").style.color=c?"silver":"black";_ge(name+"_1_label").style.color=d?"silver":"black";var _244=false;for(var i=4;i>=1;i--){if(_ge(name+"_"+i).checked&&!_ge(name+"_"+i).disabled){return;}}for(var i=1;i<=4;i++){if(!_ge(name+"_"+i).disabled){_ge(name+"_"+i).checked=true;return;}}}function _privacy_try_and_check(name,min){for(var i=min;i<=4;i++){if(!_ge(name+"_"+i).disabled){_ge(name+"_"+i).checked=true;return;}}}function _privacy_show_more(){_ge("morerow").style.display="none";_ge("lessrow").style.display=(document.all)?"block":"table-row";_ge("detailrow").style.display=(document.all)?"block":"table-row";}function _privacy_show_less(){_ge("morerow").style.display=(document.all)?"block":"table-row";_ge("lessrow").style.display="none";_ge("detailrow").style.display="none";}function woe_location_obj(ID,_247,_248,_249,bbox){this.id=ID;this.title=_247;this.sub_title=_248;this.relevance=_249;this.bbox=bbox;}F._loc_search_div={};F._loc_search_div.div_go_go_go=function(_251){this.page_type=_251;this.input_id=(this.page_type=="org")?"loc_search_input":"header_search_q";var _252=_ge(this.input_id);_252.onkeydown=_252.onkeypress=_252.onkeyup=function(e){e.stopPropagation();};this.style.display="none";F.eb_add(this);this.locations=[];this.div_show_all=0;this.current_location_index=0;var _253=document.createElement("div");_253.id="loc_search_inner_div";_253.style.width="300px";_253.style.border="0px solid black";this.appendChild(_253);var div=document.createElement("div");div.id="loc_search_header_div";div.className="Pulser";div.style.width="";div.style.margin="10px 0 5px 10px";div.style.fontWeight="normal";div.style.color="#434343";_253.appendChild(div);var div=document.createElement("div");div.id="loc_search_results_div";div.style.margin="0 0 10px 30px";_253.appendChild(div);var div=document.createElement("div");div.id="loc_search_msg_div";div.style.margin="0px 0 10px 30px";div.style.display="none";_253.appendChild(div);var img=document.createElement("img");img.id="loc_search_close";img.style.border="0px";img.style.position="absolute";img.style.left="281px";img.style.top="4px";img.src="/images/simple_close_default.gif";img.width=img.height="15";img.onclick=function(){_ge("loc_search_div").div_fade();};this.appendChild(img);F.decorate(_ge("loc_search_close"),F._simple_button).button_go_go_go();};F._loc_search_div.window_onresize=function(){if(this.style.display!="none"){this.div_show();}};F._loc_search_div.div_show=function(){if(this.style.display=="none"){this.style.visibility="hidden";}this.style.display="block";var _255=_ge("loc_search_results_div");var y=_find_y(_ge(this.input_id));if(this.page_type=="org"){var x=(_find_screen_width()-this.offsetWidth-3);y+=25;}else{if(this.page_type=="else"){var x=(_find_screen_width()-this.offsetWidth-60);if(x>_find_x(_ge(this.input_id))){x=_find_x(_ge(this.input_id));}y+=23;}else{var x=_find_x(_ge("Main"))+_ge("Main").offsetWidth-this.offsetWidth;y+=24;}}_255.style.height="";_255.style.overflow="";if(this.offsetHeight+y>_find_screen_height()){_255.style.height=(_find_screen_height()-y-52)+"px";_255.style.overflow="auto";if(this.reset_scrollTop){this.reset_scrollTop=0;_255.scrollTop=0;}}var val=100;this.style.opacity=val/100;this.style.filter="alpha(opacity="+val+")";this.style.left=x+"px";this.style.top=y+"px";this.style.visibility="visible";};F._loc_search_div.div_hide=function(){this.style.display="none";};F._loc_search_div.div_loading=function(){_ge("loc_search_results_div").style.display="none";_ge("loc_search_close").style.display="none";_ge("loc_search_header_div").className="Pulser";_ge("loc_search_header_div").innerHTML="Searching";this.reset_scrollTop=1;this.div_show_all=0;this.div_show();};F._loc_search_div.div_fade=function(){var div=this;var _257=function(){div.div_hide();};anim_do_opacity_to(div,7,35,0,"easeInQuad",_257);};F._loc_search_div.div_update_results=function(_258){if(_258){this.div_show_all=1;}var num=this.locations.length;_ge("loc_search_close").style.display="block";if(this.locations.length==0){_ge("loc_search_header_div").className="Problem";_ge("loc_search_header_div").innerHTML="No results found";_ge("loc_search_results_div").style.display="none";}else{if(this.locations.length==1){if(this.page_type=="site"){}else{setTimeout("_ge('loc_search_div').div_fade()",2000);}}_ge("loc_search_header_div").className="Confirm";_ge("loc_search_header_div").innerHTML="We found <b>"+num+"</b> match"+((num==1)?"":"es");_ge("loc_search_results_div").style.display="block";var _260=[];max_abs=20;max_to_show=8;max_to_show_if_more_than_that=5;var _261=(this.current_location_index>max_to_show_if_more_than_that||this.div_show_all)?this.locations.length:(this.locations.length>max_to_show)?max_to_show_if_more_than_that:this.locations.length;for(i=0;i<_261;i++){var _262="margin-top:3px;";if(this.page_type=="site"){var url="/map?woe_id="+this.locations[i].id;var _263="_ge('loc_search_div').div_hide();";}else{_262+=(i==this.current_location_index)?"font-weight:bold; text-decoration:none":"";var _263="_ge('loc_search_div').div_on_result_click("+i+"); return false;";if(this.page_type=="else"){var url="/map?woe_id="+this.locations[i].id;}else{var url="/photo/organize/?start_tab=map&woe_id="+this.locations[i].id;}}var html="<div style=\"padding-bottom:3px; font-size:12px; font-family:arial\"><span class=\"loc_search_found_term\">"+this.locations[i].title+"</span>, "+"<a href=\""+url+"\" style=\""+_262+"\" onclick=\""+_263+"\">"+" "+this.locations[i].sub_title+"</a>";html+="</div>";_260.push(html);}if(this.locations.length>_261){_260.push("<br><b><a href=\"#\" onclick=\"_ge('loc_search_div').div_update_results(1); return false;\">More results...</a></b>");}_ge("loc_search_results_div").innerHTML=_260.join("");}this.div_show();};F._loc_search_div.div_go_to_map=function(i,ms){if(!ms||ms<1){var _265=this.locations[i].id;var url="/map?woe_id="+_265;document.location=url;var msg="(We'll take you there now...)";}else{setTimeout("_ge('loc_search_div').div_go_to_map("+i+", "+(ms-1000)+")",ms);var msg="(We'll take you there in "+_pi(ms/1000)+" second"+((_pi(ms/1000)==1)?"":"s")+"...)";}writeDebug(msg);if(_ge("loc_search_msg_div")){_ge("loc_search_msg_div").style.display="block";_ge("loc_search_msg_div").innerHTML=msg;}};F._loc_search_div.div_on_result_click=function(i){if(this.page_type=="site"){}else{this.current_location_index=i;this.focus_on_location();this.div_update_results();}};F._loc_search_div.div_do_loc_search=function(){var _266=_ge(this.input_id).value;if(_266.length>0){if(this.loc_search_term!=_266){this.loc_search_term=_266;this.div_loading();F.API.callMethod("flickr.geocode.translate",{location:this.loc_search_term,provider_name:"woe"},this,null,null,null,0);}else{this.div_show();}}};F._loc_search_div.flickr_geocode_translate_onLoad=function(_267,_268,_269,_270){if(_267){var _271=_268.documentElement.getElementsByTagName("Result");this.locations=[];if(_271.length==0){this.div_update_results();return;}for(i=0;i<_271.length;i++){var _272=_pf(_271[i].getElementsByTagName("woe_specificprobability")[0].firstChild.nodeValue);var _273=_pf(_271[i].getElementsByTagName("woe_woeid")[0].firstChild.nodeValue);var bbox=String(_271[i].getElementsByTagName("woe_bbox")[0].firstChild.nodeValue);try{var city=String(_271[i].getElementsByTagName("City")[0].firstChild.nodeValue);}catch(er){var city="";}try{var _275=String(_271[i].getElementsByTagName("State")[0].firstChild.nodeValue);}catch(er){var _275="";}try{var zip=String(_271[i].getElementsByTagName("Zip")[0].firstChild.nodeValue);}catch(er){var zip="";}try{var _277=String(_271[i].getElementsByTagName("Country")[0].firstChild.nodeValue);}catch(er){var _277="";}_277=(_277=="United States")?"US":_277;_277=(_277=="United Kingdom")?"UK":_277;var _278="";var _279=false;if(city.length>0&&city.toLowerCase()!=this.loc_search_term.toLowerCase()){_278=_278+", "+city;}if(_275.length>0&&_275.toLowerCase()!=this.loc_search_term.toLowerCase()){_278=_278+", "+_275;}if(_277.length>0&&_277.toLowerCase()!=this.loc_search_term.toLowerCase()){_278=_278+", "+_277;}if(_278.length>2){_278=_278.substring(2,_278.length);}var _280=new woe_location_obj(_273,this.loc_search_term,_278,_272,bbox);this.locations.push(_280);}this.current_location_index=0;this.div_update_results();if(this.locations.length==1){if(this.page_type=="site"){this.div_go_to_map(0,3000);}else{this.focus_on_location();}}}else{writeDebug("Something sucked");return;}};F._loc_search_div.focus_on_location=function(){if(window.YGeoPoint==undefined){return;}var _281=this.locations[this.current_location_index].bbox;this.best_fit_points=[];this.best_fit_points.push(new YGeoPoint(_281.split(",")[1],_281.split(",")[0]));this.best_fit_points.push(new YGeoPoint(_281.split(",")[3],_281.split(",")[2]));var _282=[];for(i=0;i<this.best_fit_points.length;i++){_282.push(this.best_fit_points[i]);}var _283=map.getZoomLevel(_282);if(_283<5){_283=5;}var _282=[];for(i=0;i<this.best_fit_points.length;i++){_282.push(this.best_fit_points[i]);}var _284=map.getGeoBox(_282);var _285=map.getBoxGeoCenter(_284.min,_284.max);var _286=map.getCenterLatLon();if(_286.Lon!=_285.Lon||_286.Lat!=_285.Lat||map.getZoomLevel()!=_283){map.drawZoomAndCenter(_285,_283);_ge("map_controller").end_pan();}};
