Accordion Web Part

Brad Chapman asked on December 3, 2014 04:48

Hi There

Trying to figure out how to use javascript to open an accordion web part from a button click or similar. I have a button which links to an in page anchor, but the anchor is inside a closed accordion control. Any assistance would be most welcome.

Recent Answers


Virgil Carroll answered on December 4, 2014 00:18

If its an ASP.NET button look at the OnClientClick property. You can set a JavaScript function in this (i.e. <asp:button OnClientClick="DoFunction()" runat="server">. It will run the JavaScript before completing the button post back.

If your using an html button, you just need to move your functionality into a JavaScript call and put it in the OnClick property. Hope that helps.

0 votesVote for this answer Mark as a Correct answer

Brad Chapman answered on February 18, 2016 04:18

Dropped requirement. Thanks for your response.

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.