onBeforeActive
occurs when the user clicks on an item, but before this item becomes active and open
boolean onBeforeActive(string|number id,boolean state);
id | string|number | cell id |
state | boolean | single mode - always true, multimode - true/false (next item state) |
boolean | "return true" - allows cell to be opened, "return false" - otherwise |
Example
var myAcc = new dhtmlXAccordion(...);
myAcc.attachEvent("onBeforeActive", function(id, state) {
// your code here
return true; // allow opening
});
Related samples
Back to top