// $Id$ /** * Hide blocks in sidebars, then make them visible at the click of a button. */ if (Drupal.jsEnabled) { $(document).ready(function() { // Get all div elements of class block inside the right sidebar. var blocks = $('#sidebar-right div.sidebar-hide'); var blocks2 = $('tr.sidebar-hide'); // Get title :before var bl_content = $('.content h4.title#collapsibutton, .content h4.title#collapsibutton1'); var bl_content2 = $('.content h4.title#collapsibutton2'); // Hide them. blocks.hide(); blocks2.hide(); // Add a handler that runs when the button is clicked. $('#collapsibutton').click( function() { blocks.slideToggle("slow"); bl_content.toggleClass("visible"); }); $('#collapsibutton2').click( function() { blocks2.slideToggle("slow"); bl_content2.toggleClass("visible"); }); }); }