Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by damian on Jul 19, 2008 10:38
open dhtmlx forum
Show details of slected tree item

I want to create a website with with the tree on the left side and with a table on the right side. When the user clicks on an item in the tree a table with all the details should appear on the right side. each tree item can have one or more records which should appear on the right side. The tree items are stored in one database table and the records which belong to the item are stored in another database table.

Would be great if anybody could help me.

Thanks
Answer posted by Support on Jul 21, 2008 02:14
The tree allows to assign the onClick event handler

tree.attachEvent("onClick",function(id){
    //any custom code here
    //id - id of selected info
    show_details(id);
});

The details data can be loaded from server side by any custom logic, or stored inside tree's xml as userdata
    http://dhtmlx.com/docs/products/dhtmlxTree/doc/guide.html#xmlload