XML file format for dhtmlxFolders component


Could you please provide me the XML file format for the dhtmlxFolders component in which we need to send the data from server to the dhtmlxFolder’s loadXML() method.

Also, could you please provide various parameters which can be specified on server so that it will be honoured/available on the js side.

Vibhav Agrawal

loadXML method of dhtmlxFolders gets xml and xls files as the parameters.

The xml format is:

... ...

Items are displayed according to the xls template defined in the second parameter.

Please see ready folders sample for more details.

I wanted to know if :

  1. we can pass some userData with the foldersObject in the XML which may be used as the global parameters for dhtmlxFolder object for all items.
  2. I could find API setUserData() but could not get anything like getUserData()
  3. can we pass some custom attributes which may be used in XSL or may be in some other context, like javascript code which will be invoked on event handling.

Vibhav Agrawal

There are problems with userdata - there isn’t public method to get userdata :frowning: . DataView is much more sutable if you want to set properties to the items and access them easily. Possibly it would be better to wait for DataView release.
If you need to get userdata in Folders, I can provide you an approach that uses private methods and properties.