You would do that by getting a nodeset of the actual nodes and then grouping them by their @parentID attribute. Sounds simple, right? :-)
The thing is, grouping is tricky in XSLT (1.0) - it's perfectly doable but it looks like VooDoo magic ... it's further complicated by the fact that yoou're using CSV output instead of XML for the CheckBox Tree, which means you need some extra trickery to get the actual nodes.
So are you still looking for a solution or did you solve it in another way? Do you need it to be XSLT using the CSV output? If so, I'll gladly help you get there :-)
Group CSV list of child node ID's by their parent node ID's
Using the uComponents Checkbox Tree I have of a CSV list of child node ID's as follows
1854,1856,6241,2122
On the front-end of the site, I would like to render the selected child node ID's grouped by their parent ID's. For example
1850
- 1854
- 1856
6240
- 6241
2120
- 2122
Any ideas on how to do this using XSLT?
Hi Sean,
You would do that by getting a nodeset of the actual nodes and then grouping them by their @parentID attribute. Sounds simple, right? :-)
The thing is, grouping is tricky in XSLT (1.0) - it's perfectly doable but it looks like VooDoo magic ... it's further complicated by the fact that yoou're using CSV output instead of XML for the CheckBox Tree, which means you need some extra trickery to get the actual nodes.
So are you still looking for a solution or did you solve it in another way? Do you need it to be XSLT using the CSV output? If so, I'll gladly help you get there :-)
/Chriztian
is working on a reply...