var BS=BS||{settings:{},behaviors:{},themes:{},locale:{}};BS.jsEnabled=document.getElementsByTagName&&document.createElement&&document.createTextNode&&document.documentElement&&document.getElementById;BS.attachBehaviors=function(A){A=A||document;if(BS.jsEnabled){jQuery.each(BS.behaviors,function(){this(A)})}};if(BS.jsEnabled){document.documentElement.className="js";document.cookie="has_js=1; path=/";jQuery(function(A){BS.attachBehaviors(this)})}function checkUsername(B){var C=jQuery(B);var E=C.val();var D=wwwroot+"mod/brightv/get/";if(E!=""){jQuery("#loading-username").show();var A=jQuery.get(D+"username.php",{username:E},function(F){var G=jQuery("#username-result");if(F==1){G.removeClass("error");G.addClass("success");G.html("Available!");jQuery("#loading-username").hide()}else{G.removeClass("success");G.addClass("error");G.html("Not Available!");jQuery("#loading-username").hide()}})}}function addLoading(D,B,C){var A=false;if(C!=null){A=true}jQuery(D).each(function(){h=jQuery(this);h.createAppend("img",{id:B,src:wwwroot+"mod/template/images/loading.gif"}).css("height","1em").hide();if(A){h.show()}})}function showhide(A){jQuery("#"+A).toggle()}function loadingHTML(A){if(!A){A=""}else{A='id="'+A+'"'}return"<img "+A+' src="'+wwwroot+'mod/template/images/loading.gif" style="height:1em;" />'}function getSelectRaw(D){var D=jQuery.trim(D);var C=D.split("\n");var A=document.createElement("select");for(var B=0;B<C.length;B++){A.options[B]=new Option(C[B],C[B])}return A}function attach_country_state(C,A,D,B){(function(I){var F="India";var H="United States of America";var E=wwwroot+"mod/brightv/get/states.php";var G=A+"-loading";addLoading("#"+B,G);I(C).change(function(){var J={from:this.value,raw:"true"};if(this.value==F||this.value==H){I("#"+A+"-select").attr("disabled","true");I("#"+G).show();I.get(E,J,function(L){var K=getSelectRaw(L);I(K).attr({name:A,id:A+"-select"}).css("width","150px");I("#"+A+"-select").remove();I("#"+A).attr("name","disable").val("").hide();I("#"+A+"-holder").prepend(K);I("#"+G).hide()})}else{I("#"+A).attr("name",A).show();I("#"+A+"-select").remove()}});I(C).change(function(){suggest_url=wwwroot+"mod/brightv/get/";I("input#"+A).unbind("keypress").unbind("keydown").suggest(suggest_url+"states.php?raw=true&country="+this.value);I("input#"+D).unbind("keypress").unbind("keydown").suggest(suggest_url+"town.php?raw=true&country="+this.value+"&state="+I("#"+A).val())})})(jQuery)}function scrollTo(A){var B=$(A).offset();if(B){return $("html").animate({scrollTop:B.top+"px"},{duration:1000})}}function loadingGif(B){var A=BS.wwwroot+"media/images/"+B+".gif";return A}jQuery.preloadImages=function(){for(var A=0;A<arguments.length;A++){jQuery("<img>").attr("src",arguments[A])}};jQuery.blockWindow=function(A){if(!A){A="Please wait..."}wait='<img src="'+loadingGif("loading-alpha-bar")+'" />';msg='<h1 style="text-align:center;">'+A+"</h1>"+wait;defaults={message:msg,css:{border:"none",padding:"15px",backgroundColor:"#C8E4B1","-webkit-border-radius":"10px","-moz-border-radius":"10px",opacity:".9",color:"#156705",height:"80px"}};if(jQuery.blockUI){$(wait).ajaxStop(jQuery.unblockUI);jQuery.blockUI(defaults)}};(function(A){A.fn.adjustHeight=function(){this_height=this.height();parent_height=this.parent().height();if(this_height>parent_height||this_height<parent_height){this.parent().height(this_height)}return this};A.fn.adjustWidth=function(){this_width=this.width();parent_width=this.parent().width();if(this_width>parent_width||this_width<parent_width){this.parent().width(this_width)}return this};BS.settings=BS.behaviors.settings||{};BS.settings.fadetime=1200;A.fn.appendCloseButton=function(){var B=A(this);B.createPrepend("span",{style:"float: right; font-weight: bold; padding: 2px"},["a",{href:"#","class":"close-button",style:"color: #555;"},["close"]]);return B};BS.behaviors.displayEffect=function(){setTimeout(function(){A(".fade-in").fadeIn(BS.settings.fadetime,function(){A(this).removeClass(".fade-in")})},500);setTimeout(function(){A(".slide-down").slideDown("normal",function(){A(this).removeClass(".slide-down")})},500)};BS.behaviors.close=function(){A(".close-fade").addCloseFade();A(".close-slide").addCloseSlide()};BS.behaviors.menuAccordion=function(){A(".menu-accordion li.has-children").each(function(){var C=A(this);var E=C.children("ul").hide();var B=document.createElement("a");var D=A(B).html("&raquo;").attr("href","#").addClass("menu-toggle").click(function(){C.siblings().find("ul.open").removeClass("open").slideUp().parent().removeClass("open");A(E).toggleClass("open").slideToggle();C.toggleClass("open");return false});C.children("span").children("a").addClass("menu-label");C.children("span").append(D)})};BS.behaviors.menuSlideHover=function(){A(".menu-slidehover li.has-children").each(function(){var C=A(this);var E=C.children("ul").hide();var B=document.createElement("a");var D=A(B).html("&raquo;").attr("href","#").addClass("menu-toggle").click(function(){A(E).toggleClass("open").slideToggle();C.toggleClass("open");return false});C.children("span").children("a").addClass("menu-label");C.children("span").append(D)})};BS.behaviors.menuClick=function(){var D={position:"absolute","z-index":100};var C=3000;var B=null;A(".menu-wide-click li").mouseover(function(){A(this).addClass("active")}).mouseout(function(){A(this).removeClass("active")});A(".menu-wide-click li.has-children").each(function(){var F=A(this);var I=F.offset();var J=F.children("ul").css(D).hide();var E=document.createElement("a");var H=A(E).html("&nbsp;&nbsp;&nbsp;").attr("href","#").addClass("menu-toggle").click(function(){var L=A(this).parent().offset();var K={position:"absolute",width:A(J).width(),top:L.top+F.height(),left:L.left};F.toggleClass("open").siblings().find("ul.open").removeClass("open").hide();A(J).css(K).toggleClass("open").toggle();return false});$span=F.children("span");$span.append(H);var G=function(){B=null;A(J).hide()};F.mouseover(function(){if(B){clearTimeout(B)}}).mouseout(function(){B=setTimeout(G,C)})})};BS.behaviors.sidebarCommunitiesHeight=function(D){var C=A("#user_communities ul");var B={height:"160px",overflow:"auto"};if(C.height()>160){C.css(B)}};BS.behaviors.jsHide=function(B){A(".js-hide").hide()};BS.behaviors.externalLinks=function(B){A('a[@rel="external"]').click(function(){A(this).addClass("external");this.target="_blank"})};BS.behaviors.countryFlags=function(B){A(".country-flag").each(function(){var C=A(this);var E=C.attr("rel");if(E){var D=BS.wwwroot+"media/images/flags/"+E+".png";C.css({background:"transparent url("+D+") center right no-repeat","padding-right":"20px","margin-right":"-20px"})}})};BS.behaviors.mp3Player=function(C){var M=BS.wwwroot+"media/js/amplayer";var L="vertical-align:bottom; margin: 10px 0 5px 2px;";var J="DDDDDD";var G="BBBBBB";var K="BBBBBB";var F="666666";var B="000000";var E="000000";var O="FFFFFF";var P="333333";var Q="666666";var H="999999";var N="666666";var D="333333";var I="no";A('a.mp3:not(".mp3-processed")').each(function(){var U=A(this);var R=U.attr("href");var T=U.hide().addClass("mp3-processed").parent(".mp3-wrapper");var S='<object style="'+L+'" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"width="290" height="24" id="player" align="middle"><param name="wmode" value="transparent" /><param name="allowScriptAccess" value="sameDomain" /><param name="flashVars" value="bg=0x'+J+"&amp;leftbg=0x"+G+"&amp;rightbg=0x"+K+"&amp;rightbghover=0x"+F+"&amp;lefticon=0x"+B+"&amp;righticon=0x"+E+"&amp;righticonhover=0x"+O+"&amp;text=0x"+P+"&amp;slider=0x"+Q+"&amp;track=0x"+H+"&amp;loader=0x"+N+"&amp;border=0x"+D+"&amp;autostart=no&amp;loop="+I+"&amp;soundFile="+R+'" /><param name="movie" value="'+M+'/player.swf" /><param name="quality" value="high" /><embed style="'+L+'" src="'+M+'/player.swf" flashVars="bg=0x'+J+"&amp;leftbg=0x"+G+"&amp;rightbg=0x"+K+"&amp;rightbghover=0x"+F+"&amp;lefticon=0x"+B+"&amp;righticon=0x"+E+"&amp;righticonhover=0x"+O+"&amp;text=0x"+P+"&amp;slider=0x"+Q+"&amp;track=0x"+H+"&amp;loader=0x"+N+"&amp;border=0x"+D+"&amp;autostart=no&amp;loop="+I+"&amp;soundFile="+R+'" quality="high" wmode="transparent" width="290" height="24" name="player"align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" /></object>';S+='<span style="padding-left:20px;">'+U.text()+"</span>";A(T).prepend(S)})};BS.behaviors.showOnready=function(B){A(".show-onready").removeClass("js-hide").show()};BS.behaviors.smileys=function(B){A('.textify:not(".smileys-processed")').smileys().addClass(".smileys-processed")};BS.behaviors.selectOnFocus=function(B){A(".focus-select").focus(function(){A(this).select()})};BS.behaviors.focusOnReady=function(B){A("#focus-on-ready").focus()};BS.behaviors.cutLinksMedium=function(B){A('.link a:not(:has("*"))').each(function(C){A(this).html(A.truncateWord(A(this).html(),30))})};BS.behaviors.preloadImages=function(B){A.preloadImages(loadingGif("loading-indicator"))};BS.behaviors.shoutDelete=function(B){A("a.shout-delete").click(function(){var C=this.id.replace("sid-","");var D=this.href;var E=A("#object-"+C);if(E&&confirm("Are you sure to delete this message?")){A.get(D,{},function(F){if(C==F.ident){if(F.success){E.fadeOut("fast",function(){A(this).html("").show();addMessage(F.message,"#"+E.attr("id"))})}else{addMessage(F.message);A.scrollTo("#system-messages")}}},"json")}return false});A("#shout-delete-full").click(function(){return confirm("Are you sure to delete this message?")})};BS.behaviors.goBack=function(B){A("a.go-back").clickGoBack()};BS.behaviors.truncateExpand=function(E){var D="+more";var C="-less";var B=A(".truncate-expand").hide();var F=A('<a class="expand-action" href="#"></a>').toggle(function(){B.slideDown("slow",function(){F.text(C)})},function(){B.slideUp("slow",function(){F.text(D)})}).html(D);B.parent().append(F)}})(jQuery);jQuery.fn.clickGoBack=function(){var A=jQuery.extend({},this);jQuery.each(A,function(){this.clickGoBack()});return this};jQuery.fn.maxWidth=function(A){if($(this).width()>A){$(this).width(A)}return this};jQuery.truncateWord=function(B,A){if(A&&B.length>0&&B.length>A){B=B.substring(0,A+1)+"..."}return B};jQuery.fn.appendLoading=function(){var A=jQuery.extend({},this);var B=BS.wwwroot+"media/images/loading-indicator.gif";jQuery(this).createAppend("img",{"class":"loading-img",src:B});return this};jQuery.fn.prependLoading=function(){var A=jQuery.extend({},this);var B=BS.wwwroot+"media/images/loading-indicator.gif";jQuery(this).createPrepend("img",{"class":"loading-img",src:B});return this};jQuery.fn.smileys=function(){var B={smiley:{title:":-)",regex:/(\s|^)[:=]-{0,1}\)/gi},wink:{title:";)",regex:/(\s|^)[;=]-{0,1}\)/gi},cheesy:{title:":-&gt;",regex:/(\s|^)[:=]-{0,1}>/gi},grin:{title:":grin: :-D",regex:/(\s|^)[:=]-{0,1}D|:grin:/gi},embarassed:{title:"&#58;oops&#58; &lt;&#58;(",regex:/(\s|^):oops:|<[:=]\(/gi},angry:{title:"&gt;&#58;-(",regex:/(\s|^)\>[:=]-{0,1}\(/gi},huh:{title:"?(",regex:/(\s|^)\?([:=]-){0,1}\(/gi},sad:{title:":-(",regex:/(\s|^)[:=]-{0,1}\(/gi},shocked:{title:":-O",regex:/(\s|^)[:=]-{0,1}O/gi},cool:{title:":cool: 8-D",regex:/(\s|^)8-{0,1}[D\)]|:cool:/gi},rolleyes:{title:":roll:",regex:/(\s|^):roll:/gi},tongue:{title:":-P",regex:/(\s|^)[:=]-{0,1}P/gi},lipsrsealed:{title:":x",regex:/(\s|^)[:=]-{0,1}x/gi},undecided:{title:":/",regex:/(\s|^)[:=]-{0,1}[\\\/]/gi},cry:{title:":cry: :'(",regex:/(\s|^)[:=]\'\(|:cry:/gi},laugh:{title:":lol: xD",regex:/(\s|^)xD+|:lol:/gi},confused:{title:":S",regex:/(\s|^)[:=]-{0,1}S/gi},blank:{title:":|",regex:/(\s|^)[:=]-{0,1}\|/gi},kiss:{title:":*",regex:/(\s|^)[=:]-{0,1}\*+/gi}};var D=BS.wwwroot+"media/images/smileys/";var A=$.template(' <img src="'+D+'${smiley}.gif" title="${emoticon}" alt="${emoticon}" />');var C=$.extend({},this);jQuery.each(C,function(G){var F=this;var E="";jQuery.each(B,function(I){var H=A.apply({smiley:I,emoticon:this.title});F.innerHTML=F.innerHTML.replace(this.regex,H)})});return this};jQuery.fn.addCloseFade=function(){var A=$.extend({},this);$.each(A,function(){var B=$(this);B.appendCloseButton().addClass("clearfix").find("a.close-button").click(function(){$(this).parents(".can-close").fadeOut(BS.behaviors.fadetime,function(){$(this).remove()});return false})});return this};jQuery.fn.addCloseSlide=function(){var A=$.extend({},this);$.each(A,function(){var B=$(this);B.appendCloseButton().addClass("clearfix").find("a.close-button").click(function(){$(this).parents(".can-close").slideUp("normal",function(){$(this).remove()});return false})});return this};function addMessage(B,A){var A=A||"#content";$("<div></div>").attr("id","system-messages").addClass("can-close").html(B).hide().prependTo(A).addCloseSlide().fadeIn("slow")}(function(A){BS.behaviors.registerTips=function(){A(".register-tip").each(function(){var B=A(this);var E=B.attr("id");var C=E.split("+")[1];var D=A("#"+C);A("#"+C).focus(function(){var I=D.offset().top;var H=D.offset().left+D.outerWidth()+20;var G=D.width();var F={position:"absolute",top:I+"px",left:H+"px",width:G+"px","float":"right","background-color":"#f0f0f0",padding:"2px"};B.css(F).show()}).blur(function(){B.hide()})})};BS.behaviors.register=function(){var B='<img src="'+BS.wwwroot+'media/images/accept.gif" />';var D='<img src="'+BS.wwwroot+'media/images/error.gif" />';var C=new RegExp("^[a-zA-Z0-9]+$");A("#pname").blur(function(){var E=A(this);if(A.trim(E.val())==""){return }E.addClass("loading");A.post(BS.wwwroot+"account/check_username/",{username:E.val()},function(F){if(F.success){A("#pname-result").html("").html(B);A("#pname-errors").html("")}else{A("#pname-result").html("").html(D);A("#pname-errors").html("").html(F.message)}E.removeClass("loading")},"json")}).keyup(function(G){if(!I){var I=A(this)}if(!E){var E=A("#pname-holder").show()}if(!F){var F=A("#pname-url")}var H=I.val();if(!C.exec(H)){H=H.substring(0,H.length-1)}F.text(BS.wwwroot+"u/"+H);I.val(H)});A("#regemail").blur(function(){var E=A(this);if(A.trim(E.val())==""){return }var F=E.val();E.addClass("loading");A.post(BS.wwwroot+"account/check_email/",{email:F},function(G){if(G.success){A("#regemail-result").html("").html(B);A("#regemail-errors").html("")}else{A("#regemail-result").html("").html(D);A("#regemail-errors").html("").html(G.message)}E.removeClass("loading")},"json")});A("#regpassword2").focus(function(){A("#regpassword-result").html("");A("#regpassword-errors").html("")}).blur(function(){var G=A("#regpassword").val();var E=A("#regpassword2").val();if(G.length>5&&G==E){A("#regpassword-result").html(B)}else{var F="";if(G.length<6||E.length<6){F="Password too short"}if(G!=E){F="Does not match"}if(F){F='<span style="color:red">'+F+"</span>"}A("#regpassword-result").html(D);A("#regpassword-errors").html(F)}});if(A("#regemail").val()==""){A("#regemail").val("Your email").clearonfocus({toggleClass:"grey"})}if(A("#firstname").val()==""){A("#firstname").val("First name").clearonfocus({toggleClass:"grey"})}if(A("#lastname").val()==""){A("#lastname").val("Last name").clearonfocus({toggleClass:"grey"})}A("form#registerform").bind("submit",function(F){var E=false;if(!E&&(A("#regemail").val().length<8||!/.+@.+/.test(A("#regemail").val()))){alert("Please provide a valid email");E=true}if(!E&&A("#pname").val().length==0){alert("Please a valid password");E=true}if(!E&&A("#regpassword").val().length==0){alert("Please provide a password");E=true}if(!E&&A("#regpassword").val().length<6){alert("Your password are too short");E=true}if(!E&&(A("#regpassword").val()!=A("#regpassword2").val())){alert("Your passwords does not match");E=true}if(!E&&(A("#firstname").val().length==0||A("#lastname").val().length==0)){alert("Please enter your fist name and last name");E=true}if(!E&&A("#firstname").val().length<3){alert("Your first name are too short");E=true}if(!E&&A("#lastname").val().length<3){alert("Your last name are too short");E=true}if(!E&&((A.trim(A("#register-country").val())=="Country:")||(A.trim(A("#register-country").val()).length==0))){alert("Please select your current country");E=true}if(!E&&((A.trim(A("#register-home").val())=="Country:")||(A.trim(A("#register-home").val()).length==0))){alert("Please select your home country");E=true}if(E){return false}else{return true}});if(!A('input[value="f"]').attr("checked")){A('input[value="m"]').attr("checked","true")}A("#regemail").focus()}})(jQuery);(function(A){BS.behaviors.addFlag=function(){var B=BS.wwwroot+"flags/report/";A(".flag-this a.add-flag").click(function(){var C=A(this),D=C.parent(),F=C.metadata();var E=function(H){D.html("Reported")};var G=function(H){alert(H.message)};BS.ajaxPost(B,F,E,G);return false})};BS.behaviors.addFavorite=function(){var B=BS.wwwroot+"favorites/add/";A(".favorite-this a.add-favorite").click(function(){var C=A(this),D=C.parent(),F=C.metadata();var E=function(H){D.html("Favorite")};var G=function(H){alert(H.message)};BS.ajaxPost(B,F,E,G);return false})};BS.behaviors.addRating=function(){var B=BS.wwwroot+"rating/rate/";A(".rating").each(function(){var D=A(this);var C=D.find("form").eq(0);C.submit(function(E){var F=C.serialize();C.disableForm();var G=function(H){D.fadeOut("fast",function(){D.html(H.message).fadeIn()})};BS.ajaxPost(B,F,G,G);E.preventDefault();return false});C.find('select[@name="rate"]').change(function(){C.submit()})})};BS.behaviors.shoutQuickReply=function(){A("a.quickreply-toggle").click(function(){var B=A(this).metadata();A("#replyform-"+B.object_id).slideToggle("slow");return false})};BS.behaviors.addThis=function(){addthis_pub="rho";addthis_brand="BrightVillage";addthis_options="favorites, email, facebook, delicious, google, live, twitter, more";addthis_script="http://s7.addthis.com/js/152/addthis_widget.js";var B=function(){return addthis_open(this,"","[URL]","[TITLE]")};var D=function(){return addthis_close()};var C=function(){return addthis_sendto()};$es=A("a.addthis");if($es.length>0){$es.hover(B,D).click(C);A.getScript(addthis_script)}};BS.behaviors.ajaxLoad=function(){A("div.ajaxload").each(function(){var C=A(this).metadata();if(C.url){var B=C.url;delete C.url;BS.ajaxLoad(this,B,C)}})};BS.ajaxLoad=function(B,E,F,H){var D=A(B);var C=A("<img/>").attr("src",loadingGif("loading-circle-big"));var G=A("<div/>").html(C).css("text-align","center");D.html(G);return D.load(E,F,H)};BS.ajaxPost=function(B,D,C,F){if(!C){var C=function(G){return }}if(!F){var F=function(G){alert(G.message)}}var E=function(G){if(G.success){C(G)}else{F(G)}};A.post(B,D,E,"json")};BS.behaviors.disableOnSubmit=function(){A("form.disable-onsubmit").each(function(){var B=A(this);B.submit(function(C){B.disableForm()})})};jQuery.fn.disableForm=function(){var B=jQuery.extend({},this);jQuery.each(B,function(){A(this).find('input[@type="submit"]').attr("disabled","disabled")});return this}})(jQuery);(function(B){BS.behaviors.setDelete=function(D){B("a.set-delete").click(function(){var E=this.id.replace("set-delete-","");var F=this.href;var G=B("#set-"+E);if(G&&confirm("Are you sure to delete this set?")){B.post(F,{},function(H){if(E==H.ident){if(H.success){G.fadeOut("fast",function(){B(this).remove();addMessage(H.message,"#set-messages")})}else{addMessage(H.message,"#set-messages")}}},"json")}return false})};BS.behaviors.proccessSetForm=function(){B("form#setform").bind("submit",function(D){if(B("#name").val().replace(/ /g,"").length==0){alert("Your set name is empty");B("#name").focus();return false}return true});B("#name").focus()};function A(G){var D=B(G);var F=D.attr("href");var H=B(F);var E=F.replace("#shouts-","");H.siblings().hide();H.show();B("input#shouts-type").val(E);D.addClass("active").siblings().removeClass("active");D.parent().addClass("tabberactive").siblings().removeClass("tabberactive")}function C(E){var D=E;if(!D){D="message"}else{D=D.replace("#","")}B("a#shouts-tab-"+D).click()}BS.behaviors.shoutsHandler=function(F){var E=true;var D=B(".shouts_form");B.preloadImages(loadingGif("loading-bar"));B(".shouts-type a").each(function(){B(this).click(function(){A(this);if(E){D.find(".tabbertab").fadeIn("slow");E=false}return false})});D.submit(function(J){var G=true;var H=D.find('input[@name="type"]').eq(0).val();if(!H){H="message"}D.find('[@name="content"]').each(function(){var L=B(this).val();if(B.trim(L)==""){alert("Please write something...");G=false}});if("link"==H&&G){D.find('input[@name="link"]').each(function(){var M=B(this).val();var L=/[a-z0-9]+:\/\/.+/i;if(!L.exec(M)){alert("Please provide a valid link. (ex. http://example.com)");G=false}})}if("file"==H&&G){D.find('input[@name="file"]').each(function(){var L=B(this).val();if(B.trim(L)==""){alert("Please select a file...");G=false}})}if("event"==H&&G){D.find('input[@name="title"]').each(function(){var L=B(this).val();if(B.trim(L)==""){alert("Please write the name event");G=false}});D.find('input[@name="location"]').each(function(){var L=B(this).val();if(B.trim(L)==""){alert("Please write the location event");G=false}});D.find('input[@name="start-hour"]').each(function(){var L=B(this).val();if(B.trim(L)==""){alert("Please write a start hour");G=false}});D.find('input[@name="end-hour"]').each(function(){var L=B(this).val();if(B.trim(L)==""){alert("Please write a end hour");G=false}})}if(G){var K=B('<div class="loading"><span><img src="'+loadingGif("loading-indicator")+'" alt="Please wait..." /> Please wait...</span></div>').css({"font-size":"1.2em"});var I=D.find("div.submit").eq(0);I.append(K);I.find("input:submit").hide()}else{J.preventDefault()}return G})};jQuery.timers.registry=new Array();jQuery.timers.clear=function(D){if(D){clearTimeout(D);clearInterval(D)}else{jQuery.map(jQuery.timer.registry,jQuery.timer.clear)}};jQuery.timers.setTimeout=function(F,D){var E=setTimeout(F,D);jQuery.timers.registry.push(E);return E};jQuery.timers.setInterval=function(F,D){var E=setInterval(F,D);jQuery.timers.registry.push(E);return E};BS.behaviors.displayOnLoad=function(D){B(".display-on-load").slideDown().removeClass("hide").removeClass("display-on-load")};jQuery(window).unload(jQuery.timers.clear)})(jQuery);