DHTMLX Docs & Samples Explorer

getAttribute(itemId, attribute)

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

returns the value of the specified item attribute (the original value can be defined as a part of XML | JSON data)

  • itemId - the item ID
  • attribute - the attribute name
var itemName = tree.getAttribute("item1","text");