I am using the following code to open and close a div ( slide up/down ) using js
I have the slide down event attached to a button and the slide up event sttached to
try this. it allows multiple items so isn't ID specific. and supports any content loaded via AJAX as well. jsfiddle is here
Open
and
$('.toggler').live('click',function(){
$(this).parent().children().toggle(); //swaps the display:none between the two spans
$(this).parent().parent().find('.toggled_content').slideToggle(); //swap the display of the main content with slide action
});