function setDisplay(a,c){if($(a)){var b=$(a);b.style.display=c}}function toggleDisplay(a){var e=a+"Body";var c=a+"Hdr";if($(e)){var b=$(e);var g=b.style.display;var f="collapse";var d="expanded";if(g=="none"){setDisplay(e,"block");addClass(c,d);desist(a)}else{setDisplay(e,"none");addClass(c,f);persist(a,f)}}else{if($(a)){var b=$(a);var g=b.style.display;var f="collapse";var d="";if(g=="none"){setDisplay(a,"block")}else{setDisplay(a,"none")}}}}function addClass(a,d){if($(a)){var b=$(a);var c=b.className;b.className=d}}function persist(b,c){var a=new Date();a.setFullYear(a.getFullYear()+10);document.cookie=b+"="+c+"; path=/; expires="+a.toGMTString()}function desist(b){var a=new Date();a.setFullYear(a.getFullYear()-10);document.cookie=b+"=test; path=/; expires="+a.toGMTString()}function scheduleShow(){if(this.getElementsByTagName){setTipShow(this.getElementsByTagName("div"));setTipShow(this.getElementsByTagName("span"))}}function setTipShow(b){for(var a=0;a<b.length;a++){if(b[a].className.indexOf("toolTip")!=-1){b[a].mouseover=true;if(b[a].id){window.setTimeout('showTip("'+b[a].id+'")',250)}}}}function scheduleHide(){if(this.getElementsByTagName){setTipHide(this.getElementsByTagName("div"));setTipHide(this.getElementsByTagName("span"))}}var length=1000;function setTipHide(b){for(var a=0;a<b.length;a++){if(b[a].className.indexOf("toolTip")!=-1){b[a].mouseover=false;if(b[a].id){window.setTimeout('clearTip("'+b[a].id+'")',length)}}}}function showTip(b){var a=$(b);if(a.mouseover){a.style.display="block"}}function clearTip(b){var a=$(b);if(!a.mouseover){a.style.display="none"}else{window.setTimeout('clearTip("'+b+'")',1000)}}function recordParentMouseover(){this.parentNode.mouseover=true}function recordParentMouseout(){this.parentNode.mouseover=false}function setTooltips(a,e){if(e){length=e}if(!a){a="span"}if(document.getElementsByTagName){var c=document.getElementsByTagName(a);for(var b=0;b<c.length;b++){var d=c[b];if(d.className.indexOf("moreInfo")!=-1){d.onmouseover=scheduleShow;d.onmouseout=scheduleHide;setEvents(d,"div");setEvents(d,"span")}}}}function setEvents(c,a){var d=c.getElementsByTagName(a);for(var b=0;b<d.length;b++){if(d[b].className.indexOf("toolTip")!=-1){d[b].onmouseover=recordParentMouseover;d[b].onmouseout=recordParentMouseout}}}function swapDescriptions(b){var e=b.parentNode.parentNode;var d=e.getElementsByTagName("p");for(var a=0;a<d.length;a++){var c=d[a];if(c.className.indexOf("productDescriptionExcerpt")>=0){c.style.display="none"}else{if(c.className.indexOf("productDescriptionFullText")>=0){c.style.display="block"}}}}function openLoginLite(a,b){if(jQuery("#loginLiteMessage").length==0){jQuery("#loginLite").load("/utility/loginlite",function(){openLoginLite(a)})}else{if(!a){a="<strong>Hey smarty!</strong>  To make your vote count, <a href=\"#\" onclick=\"jQuery('#login-option').show(); jQuery('#join-option').hide(); return false;\">login</a> or <a href=\"#\" onclick=\"jQuery('#login-option').hide(); jQuery('#join-option').show(); return false;\">join Squidoo</a> for free."}jQuery("#loginLiteMessage").html(a);jQuery("#default_onion").show();jQuery("#loginLite").show();jQuery("#login_redirect").val("/"+theLensName);jQuery("#reg_redirect").val("/"+theLensName);window.scrollTo(0,0);if(b){b()}}}function openPlexSubmit(c,a,b){if(b){if(member_id!=""){Element.show("add-options"+c);Element.show("bulkSurfer"+c);new Ajax.Updater("captcha_"+c,"/utility/load_captcha",{asynchronous:true});return false}else{$("loginLiteMessage").innerHTML="<strong>Hey smarty!</strong>  To make your vote count, <a href=\"#\" onclick=\"Element.show('login-option'); Element.hide('join-option'); return false;\">login</a> or <a href=\"#\" onclick=\"Element.hide('login-option'); Element.show('join-option'); return false;\">join Squidoo</a> for free.";Element.show("loginLite","overlay");$("login_redirect").value="/"+a;$("reg_redirect").value="/"+a;window.scrollTo(0,0);return true}}else{Element.show("bulk"+c)}}function plexSubmit(e,c){var d=null;myform=$("plexoForm"+e);d=validate(myform);if(d){var b=myform.getElementsByTagName("input");var a=myform.getElementsByTagName("textarea");postString=saveFields(b);postString+=saveFields(a);new Ajax.Request("/utility/plexo_submit/"+e,{asynchronous:true,method:"post",postBody:postString,onSuccess:function(f){if(f.responseText=="captcha_error"){alert("The security word you entered is incorrect. Please try again.")}else{if(f.responseText==null||f.responseText==""){if(c=="manual"){$("add-options"+e).innerHTML='<div style="text-align: center; font-weight: bold; width: 80%; padding: 20px;"><img src="/images/btn-submitted.gif" alt="Submitted" style="text-align: center;" /> <br /><br />Thanks! Your item was submitted successfully, and is now pending approval from the lensmaster.</div>'}else{$("add-options"+e).innerHTML='<div style="text-align: center; font-weight: bold; width: 80%; padding: 20px;"><img src="/images/btn-submitted.gif" alt="Submitted" style="text-align: center;" /> <br /><br />Thanks! Your item was submitted successfully and will appear shortly. Don\'t forget to vote for it!</div>'}}else{alert("There was a problem saving your submission:\n\n"+f.responseText)}}}})}return false}function plexVote(lmi,lens_name,item_id,direction){if(member_id&&member_id!=""){new Ajax.Request("/utility/plexo_vote/"+item_id+"/"+direction,{onSuccess:function(response){if(response.responseText.indexOf("|")==0){var curPoints=response.responseText.substr(1);var children=$("plexItem"+item_id).getElementsByTagName("div");for(var i=0;i<children.length;i++){if(direction=="up"){if(children[i].className.indexOf("vote-up")>-1||children[i].className.indexOf("voted-up")>-1){children[i].className="voted-up"}else{if(children[i].className.indexOf("vote-down")>-1||children[i].className.indexOf("voted-down")>-1){children[i].className="vote-down"}}}else{if(direction=="down"){if(children[i].className.indexOf("vote-up")>-1||children[i].className.indexOf("voted-up")>-1){children[i].className="vote-up"}else{if(children[i].className.indexOf("vote-down")>-1||children[i].className.indexOf("voted-down")>-1){children[i].className="voted-down"}}}}}var newDisplay="";if(curPoints==-1||curPoints==1){newDisplay=curPoints+' point - <a href="javascript:window.location.reload();" title="refresh the page">refresh to rerank</a>'}else{newDisplay=curPoints+' points - <a href="javascript:window.location.reload()" title="refresh the page">refresh to rerank</a>'}var voteHistory=eval("voted"+lmi);if(!voteHistory[item_id]||voteHistory[item_id]!=direction){new Effect.Highlight("plexItem"+item_id);window.eval("voted"+lmi+"["+item_id+'] = "'+direction+'"')}$("pointsDisplay"+item_id).innerHTML=newDisplay}else{alert("There was a problem saving your vote. The problem was: \n\n"+response.repsponseText)}},asynchronous:true,method:"post"});return false}else{$("loginLiteMessage").innerHTML="<strong>Hey smarty!</strong>  To make your vote count, <a href=\"#\" onclick=\"Element.show('login-option'); Element.hide('join-option'); return false;\">login</a> or <a href=\"#\" onclick=\"Element.hide('login-option'); Element.show('join-option'); return false;\">join Squidoo</a> for free.";Element.show("loginLite","loginLiteMessage","default_onion");Element.show("default_onion");$("login_record_vote").value=item_id+"/"+direction;$("login_redirect").value="/"+lens_name;if(plexBack){$("login_redirect").value="/"+lens_name+"?plexBack="+escape(plexBack)}$("reg_record_vote").value=item_id+"/"+direction;$("reg_redirect").value="/"+lens_name;if(plexBack){$("reg_redirect").value="/"+lens_name+"?plexBack="+escape(plexBack)}window.scrollTo(0,0);return false}}function plexWidget(e,d,b,a,c){if(c){contents='<div id="plex'+d+'"><a href="'+c+'">Click through to see the plexo</a></div>'}else{contents='<div id="plex'+d+'"></div>'}contents+='<script type="text/javascript" src="http://www.squidoo.com/scripts/plexo/syndicate.php?plex_id='+d+'"><\/script>\n';contents+='<script type="text/javascript">\n';contents+="  openPlexo({\n";contents+='    "container" : "plex'+d+'"';if(b=="sidebar"){contents+=',\n    "size" : "sidebar"\n'}if(a!=undefined){contents+=',\n    "num_results" : "'+a+'"\n'}contents+="  });\n";contents+="<\/script>";$("widget-code-box"+e).value=contents;Element.show("widget-code"+e)}function openHelper(lmi,url){var width=550;var height=420;var _left=((screen.width-width)>>1);var _top=((screen.height-height)>>1);myWin=eval("helperWindow"+lmi);myWin=window.open(url,"modules_id"+lmi+"_helper","status=yes,scrollbars=yes,resizable=yes,width="+width+",height="+height+",left="+_left+",top="+_top);if(myWin.opener==null){myWin.opener=window}myWin.opener.name="opener";myWin.focus()}function showItems(d,a,c){var b="";if(a){b="Surfer"}Element.show("plexSubmission"+b+d);if(!c){Element.hide("bulk"+b+d)}new Effect.Highlight("bulkList"+b+d)}function hideToolbox(){$("toolbox-contents").hide();$("toggle-off").hide();$("toggle-on").show();var b=new Date();b.setTime(b.getTime()+(60*24*60*60*1000));var a=b.toGMTString();document.cookie="hide_toolbox = true; expires="+a+"; path=/";return false}function showToolbox(){$("toolbox-contents").show();$("toggle-off").show();$("toggle-on").hide();var b=new Date();b.setTime(b.getTime()+(-1*24*60*60*1000));var a=b.toGMTString();document.cookie="hide_toolbox = true; expires="+a+"; path=/";return false}function hideSquidUTips(){$("tip-squidu").hide();var b=new Date();b.setTime(b.getTime()+(60*24*60*60*1000));var a=b.toGMTString();document.cookie="hide_squidu_tips = true; expires="+a+"; path=/";return false}var RecaptchaOptions={theme:"white",tabindex:8};if(typeof Effect=="undefined"){var Effect=function(){return{Highlight:function(c,a){try{if(typeof c=="object"){c=c.id}jQuery("#"+c).fadeIn("fast");jQuery("#"+c).fadeOut("fast");jQuery("#"+c).fadeIn("fast")}catch(b){}},Fade:function(d,b){try{var a="slow";if(typeof b=="object"){a=b*1000}if(typeof d=="object"){d=d.id}jQuery("#"+d).fadeOut(a)}catch(c){}},Appear:function(c,a){try{if(typeof c=="object"){c=c.id}jQuery("#"+c).show()}catch(b){}},Pulsate:function(c,a){try{if(typeof c=="object"){c=c.id}jQuery("#"+c).fadeIn("fast");jQuery("#"+c).fadeOut("fast");jQuery("#"+c).fadeIn("fast");jQuery("#"+c).fadeOut("fast");jQuery("#"+c).fadeIn("fast");jQuery("#"+c).fadeOut("fast");jQuery("#"+c).fadeIn("fast");jQuery("#"+c).fadeOut("fast");jQuery("#"+c).fadeIn("fast")}catch(b){}},Grow:function(c,a){try{if(typeof c=="object"){c=c.id}jQuery("#"+c).show()}catch(b){}},BlindUp:function(c,a){try{if(typeof c=="object"){c=c.id}jQuery("#"+c).slideUp("fast")}catch(b){}},BlindDown:function(c,a){try{if(typeof c=="object"){c=c.id}jQuery("#"+c).slideDown("fast")}catch(b){}}}}()}if(pageLoadActions==undefined){var pageLoadActions=[];var loaded=false}onPageLoadHandler=function(){if(!loaded){for(iterator=0;iterator<pageLoadActions.length;iterator++){var a=pageLoadActions[iterator];if(typeof a=="function"){pageLoadActions[iterator]()}else{}}loaded=true}};function hasPageLoaded(){if(typeof(pageBottomLoaded)!="undefined"){onPageLoadHandler()}}jQuery(document).ready(onPageLoadHandler);window.setTimeout(hasPageLoaded,12000);
