// JavaScript Document $(document).ready(function() { // global // d_bar_tab show, hide and change picture $(".d_bar_tab").toggle( function() { $(".destination_bar").animate( { top:"0px" }, 500); $(".d_bar_tab").attr({src: "img/d_bar_tab_close.gif"}); }, function() { $(".destination_bar").animate( { top:"-75px" }, 500); $(".d_bar_tab").attr({src: "img/d_bar_tab_open.gif"}); } ); // tabs handler $("#tabs ul li a:first").removeClass('inactive'); $("#tabs ul li a").click(function () { $("#tabs ul li a").addClass('inactive'); $(this).removeClass('inactive'); var currentTab = $(this).attr('href'); $('.tab').hide(); $(currentTab).show(); return false; }); // js template1 // home accordion handler $(".ah").click(function() { $(this).parent().parent().find(".ah.open").addClass("closed").removeClass("open"); $(this).parent().parent().find(".ac.open").addClass("closed").removeClass("open"); $(this).addClass("open").next().removeClass("closed").addClass("open"); }); // js template2 // content accordion handler $(".ac_info_head").click(function() { $(this).parent().children(".ac_info_cont").toggle(); $(this).children("a").toggleClass("open"); }); });