Toggle button inside accordion using jquery
问题 I want to create a toggle button inside an accordian. Here is what I was trying to do. Javascript $j("div a").live('click', function() { $j("#toggleButton").click(function () { $j("#test p").slideToggle("slow"); }); }); HTML is: <div id="accordion"> <h3><a href="#">Number 1</a></h3><div><h4> Error1:</h4><p> some contents here </p><div id="content1"><input type="button" value="Hide" id="toggleButton" style="float:right;"><div id="test"> <p>jhfsnv jv jsdhv jsdvb </p></div></div></div> <h3><a