I have the following inside of my Header Template of an Ajax Accordion:
<ajaxToolkit:Accordion runat="server" ID="accQuestions" TransitionDuration="250" FramesPerSecond="30" HeaderCssClass="moduleheader" HeaderSelectedCssClass="moduleheader selected" RequireOpenedPane="false">
<HeaderTemplate>
<div class="image" title="Expand/collapse">
<a class="heading_link" href="<%#GetQuestionUrl((Answer)Container.DataItem) %>" >Question Header</a>
</div>
</HeaderTemplate>
And the following Javascript that assigns a click event to all of the anchors:
$("a.heading_link").click(function() {
$(this).parent().click();
return false;
});
I need this to work without JS as well, which is why I still generate the HREF on the links, so I'm just intercepting the click and then invoking the parent click which in turn toggles the accordion header.
This works in IE but no Firefox, Chrome.