$(document).ready(function() {// -----------------------// CSS TWEAKS// -----------------------//$("#rightContent h4").css("display","none");/*Show menu */$("#tabMenu").css("display","block");/* if js change some css *//* show = #filter, .count *//* hide =  */$("#filter").css("display","block");$(".count").css("display","block");//--------------------// LOGIN BOX//--------------------$(".loginButt").click(function(){$("#loginBox").fadeIn();return false;});$(".closeLogin").click(function(){$("#loginBox").fadeOut();return false;});// -----------------------// TABMENUS// -----------------------var tabContainers = $('#popularity, #name, #category, #feeband, #tags, #summary, #biography, #photos, #testmonials, #testimonials, #testimonials2, #video, #video2, #services, #benefits, #overview');$('ul.tabMenu a').click(function () {//tabContainers.hide().filter(this.hash).show();tabContainers.hide().filter(this.hash).fadeIn();  $('ul.tabMenu a').removeClass('current');$(this).addClass('current');        return false;    }).filter(':first').click();//-----------------------------------//------FILTER NAMES ------//-----------------------------------$("#filter").keyup(function () {    var filter = $(this).val(), count = 0;    $(".filtered:first li").each(function () {        if ($(this).text().search(new RegExp(filter, "i")) < 0) {            $(this).addClass("hide");        } else {            $(this).removeClass("hide");            count++;        }    });    $("#filter-count").text(count);});//---------------------------------------------------//--------SPEAKER OF THE MONTH ----//--------------------------------------------------$(".show_hide").click(function() {$(".sotm").slideToggle('fast');});// -------------------// LOG IN POPUP// -------------------// toggles the slickbox on clicking the noted link 		  $('a#sm_toggle').click(function() {		    $('#sm_outer').slideToggle(400);		    return false;		  });		 		});		$(document).ready(function() {		  $('a#loginLink').click(function() {			if (document.getElementById('loginFormMiniMain').style.display == 'block')			{				$('#loginFormMiniMain').fadeOut('fast');			}			else			{				$('#loginFormMiniMain').fadeIn('fast');				document.getElementById('username').focus();			}		    return false;		  });// ----------------------------// CATEGORY LIST// ----------------------------//$("#nav_categories>li a:not(#nav_categories>ul>li a)").after("<span>[+]</span>");//-----------------------------------------------------------//----only add [+] to li's which have sub menus//-----------------------------------------------------------var $hasSub = $("#nav_categories ul").prev();$hasSub.after("<span>  [+]</span>");//-------------------------------------------------------//-----------------hide ul until  [+] click <span>//-------------------------------------------------------$('#nav_categories>li>ul').hide();  $('#nav_categories>li').click(function(){  // check that the menu is not currently animated  if ($('#nav_categories ul:animated').size() == 0) {  // create a reference to the active element (this)  // so we don't have to keep creating a jQuery object  $heading = $(this);  // create a reference to visible sibling elements  // so we don't have to keep creating a jQuery object  $expandedSiblings = $heading.siblings().find('ul:visible');  if ($expandedSiblings.size() > 0) {  $expandedSiblings.slideUp(200, function(){   $heading.find('ul').slideDown(200);    });   }   else {  $heading.find('ul').slideDown(800);   }   }   });   //-------------------------------------------------------//------show ul if view that category-----------//-------------------------------------------------------// ----------------------------//        SPEAKERS// ----------------------------$('.speaker').click(function(){  });// ----------------------------//        DATE PICKER// ----------------------------/* $("#event_date").datepicker({ dateFormat: 'dd-mm-yy' }) */// ----------------------------//        POP UP WINDOWS// ----------------------------$('A[rel="external"]').click( function() {        window.open( $(this).attr('href') );        return false;    });});