adam0101
adam0101

Reputation: 30995

Remove JQuery accordion behavior?

I have a requirement to display content with an accordion or without. Is there a way to easily add and remove the accordion behavior? In other words, can I revert the styles and behaviors applied to my divs to a state before they were "accordionized"?

Upvotes: 1

Views: 103

Answers (1)

Kevin B
Kevin B

Reputation: 95022

Yes, use the destroy method.

$("#accordion").accordion("destroy")

http://api.jqueryui.com/accordion/#method-destroy

most if not all official jQuery UI widgets have this method.

Upvotes: 2

Related Questions