Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Gaurav Arora on Nov 26, 2008 23:45
open dhtmlx forum
Accordion - get open/close state

Hi,

Is there any way of knowing if an item in accordion is opened or closed? I need to get the state of accordion item. Something like accordion.itemId.getState().

Thanks,
Gaurav Arora
Answer posted by Support on Nov 27, 2008 02:32
Hello,

Unfortunately such feature is absent. It will added in future release.

Now you can use the following code:

if (String(dhxAccord.idPull[itemId]._content.className).search("dhx_acc_item_content_opened") != -1) {
    // item opened
} else {
    // item closed
}