Check documentation for the latest version of dhtmlxSuite onBeforeActive DHTMLX Docs

onBeforeActive

occurs when the user clicks on an item, but before this item becomes active and open

boolean onBeforeActive(string|number id,boolean state);
idstring|numbercell id
statebooleansingle 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