DHTMLX Docs & Samples Explorer

addItem(itemId, itemText)

Required library edition: This method works with any edition of DHTMLX library
Required library file: dhtmlxaccordion.js

adds a new item

  • itemId - item's id
  • itemText - item's text
var dhxAcc = new dhtmlXAccordionObject(...);
  // adding items
dhxAcc.addItem("item_a", "The Secret of Monkey Island");
dhxAcc.addItem("item_b", "Monkey Island 2: LeChuck's Revenge");
dhxAcc.addItem("item_c", "The Curse of Monkey Island");
    ...