Populate Checkbox Tree sys_CheckBoxTree from XML file

Hello,

I have been looking all through the forum and documentation but cannot find an explanation of how to do this.

I have an xml file which is structured like this:


<?xml version="1.0" encoding="utf-8"?>
<tree label="Taxonomy">
  <node id="1" Label="Built environment">
    <node id="12" Label="Asset Management">
      <node id="97" Label="Auditing" />
      <node id="98" Label="Facilities management" />
    </node>
    <node id="13" Label="Built environment technologies">
      <node id="102" Label="Building standards" />
    </node>
  </node>
</tree>

Is it possible to use just this file (which will occasionally be updated) to populate a checkboxtree field?

If so are there any examples or instructions on how to do so?

Thanks

Chris

That should definitely work. I know that I have populated one with an externally generated XML file from a remote Grails application using an XML Application that used a proxyqueryresource exit to pull down the remote XML and transform it into the right format.

If your XML is in the right format you may just be able to set the tree_source_url property and skip the transform.

This thread might help.

http://forum.percussion.com/showthread.php?10432-Populate-Checkbox-Tree-sys_CheckBoxTree-from-XML-Application(s)

I’ve looked all through that post but they are using a query to create the list.

The last posts mentions sys_CheckboxTreeControl.dtd but doesn’t elaborate on what to do with it…neither does the documentation as far as I can tell.