How to get the state of a non-initalized accordion?
Hello,
I have an issue with the Accordion jqueryUI widget. I'm appling several times over the same html element the accordion with different data loaded from Ajax data. The problem is that it only works the first time (when page loads).
I need to apply the destroy() method to the accordion before reload it again to solve this, but the problem is that I before apply this method,
- $('#my-layer-id').accordion('destroy');
the accordion must be initialized, but the first time is not initialized.
There's any way to get the first state of the accordion? I mean one manner to do the next:
- if(<State of accordion initialized yet>)
- $('#my-layer-id').accordion('destroy');
Many thanks,
Dani (Barcelona)