var mytree = new dhtmlXTreeObject(parent,width, height, rootId )
where
<div id='my_tree_here'></div> <script> //common init code var mytree = new dhtmlXTreeObject("my_tree_here","100%","100%",0); </script>
Layout, Window, Accordion, Tabbar can create a tree inside their cells by using
some_component.cells(some_id).attachTree(rootId)
In this case rootId has same meaning as in native initialization ( it is an optional, 0 used as default value )
Starting from 2.5 version, tree can be initialized by object notation
var mytree = new dhtmlXTreeObject({ some_option1:some_value_1, some_option2:some_value_2, ... some_optionN:some_value_N, })
tree = new dhtmlXTreeObject({ parent:"a_tree", image_path:"codebase/imgs/csh_books/", onClick:function(){ alert("I'm clicked"); }, xml:"tree3.xml" });