var Popover=function(b,a){this.url=b,this.options=a,this.viewportwidth="",this.viewportheight="",this.showing=false;};var glossary=glossary||{Close:"Close",previous_image:"Previous Image",next_image:"Next Image"}; var websover={extraWidth:22,extraHeight:68,currentShadow:null,currentWrap:null,currentBorder:null,currentPopover:null,currentContent:null,garbageBin:null,imageToLoad:null,loadSrcTo:null,removeBadElements:function(){if(/msie|MSIE 6/.test(navigator.userAgent)){var b=document.getElementsByTagName("SELECT"); for(var a=0;a";p.setAttribute("id","websover_lightbox_next");p.setAttribute("title",glossary.next_image);p.setAttribute("href","#"); p.setAttribute("onclick","return false");p.innerHTML=""+glossary.next_image+"";g.appendChild(f);g.appendChild(p);t.appendChild(s);t.appendChild(g); b.appendChild(t);websover.currentContent=b;var a=0;var d=function(e){if(r){if(e===-1){e=l.length-1;}if(e===l.length){e=0;}a=e;}else{if(a===0){f.style.display="none"; }if(a===1){f.style.display="block";}if(a===l.length-2){p.style.display="block";}if(a===l.length-1){p.style.display="none";}}websover.loadSrcTo=s;websover.initWatchImgLoad(l[e]); return false;};var j=function(i){return d(--a);};var o=function(i){return d(++a);};if(typeof addEventListener==="undefined"){f.attachEvent("onclick",j); p.attachEvent("onclick",o);}else{f.addEventListener("click",j,false);p.addEventListener("click",o,false);}d(a);}else{if((typeof this.url.indexOf==="function"&&(this.url.indexOf(".png")>0||this.url.indexOf(".jpg")>0||this.url.indexOf(".jpeg")>0||this.url.indexOf(".gif")>0))||(typeof c.type!=="undefined"&&c.type==="IMG")){websover.initWatchImgLoad(this.url); websover.currentContent=websover.imageToLoad;}else{if(typeof this.url=="string"){websover.currentContent=document.createElement("iframe");websover.currentContent.setAttribute("id","websover_iframe"); websover.currentContent.setAttribute("rel",this.url);websover.currentContent.setAttribute("name","popoverIframe");websover.currentContent.setAttribute("frameborder","0"); try{websover.currentContent.frameBorder=0;}catch(q){}websover.currentContent.setAttribute("scrolling",m);websover.currentContent.src=this.url;websover.currentContent.onload=function(){websover.currentContent.style.visibility="visible"; };websover.currentContent.style.cssText="visibility: hidden; "+(m==="no"?"overflow: hidden;":"overflow: auto;");}else{this.url.style.display="block";websover.currentContent=this.url; websover.currentContent.className="websover_content";}}}websover.currentPopover.innerHTML='
'+c.heading+""+(c.closeButton?''+glossary.Close+"":"")+'
'; websover.currentWrap.style.display="block";websover.currentPopover.style.width=websover.width+"px";websover.currentBorder.style.width=websover.width+"px"; websover.currentBorder.style.left=-parseInt((websover.width+websover.extraWidth)/2)+"px";websover.currentBorder.style.top=-parseInt((websover.height+websover.extraHeight)/2)+"px"; var h=document.getElementById("websover_iframe_container");if(typeof this.url=="string"){h.style.cssText="height: "+(websover.height-26)+"px";}h.appendChild(websover.currentContent); if(websover.currentContent.tagName==="IFRAME"){window.setTimeout(function(){websover.currentContent.style.visibility="visible";},500);}else{if(websover.currentContent.tagName==="IMG"){}else{websover.resize({height:websover.currentContent.offsetHeight,width:websover.width}); websover.currentBorder.style.height="auto";}}if(document.getElementById("websover_close")){document.getElementById("websover_close").onclick=this.hide; }this.showing=true;websover.reposition();return false;},hide:function(){if(typeof this.options!="undefined"&&this.options.onClose){this.options.onClose(); }websover.hide();this.showing=false;return false;}};