Categories | Question details Back To List | ||
Weird glitch using getAllChecked I have just switched to the latest professional version of DHTMLX Tree. There is now a weird glitch that occurs every time i call the tree.getAllChecked method. If i choose a full nodes that has 2 children for some reason it returns all of them (the parent and two child) plus some non-existant one, empty entries not seen in the trees separated by commas. Any idea why this would occur ? Thanks for the help Answer posted by Support on Mar 18, 2008 04:06 >> it returns all of them (the parent and two child) plus some
non-existant one, empty entries not seen in the trees separated by
commas Such a situation can be if the Smart XML Parsing or the Smart Rendering mode is enabled - when tree's items are not parsed completely. You can use following approach to get an array of not empty items: var arr = tree.getAllChecked().split(",") var checked_items = []; for(var i=0; i < arr.length;i++){ if(arr[i]!="") checked_items[checked_items.length] = arr[i]; } |