Remote XML

I tried to call a feed which is formatted as XML but could not figure out how to use in code. I had to reformat the data as such




This is not the format remotely…it is something like

<?xml version="1.0" encoding="UTF-8"?> 10 3 true

How can I use this in code to get for example


You can add the next line before data loading.


after that normal xml loading will work

{ view:"list", id:"mylist", url:"alter.xml", datatype:"xml",select:true, template:"#popularity#", select:true, type: { width: "auto" } }

Also, if you need to have a better control other data parsing - custom data driver can be implemeted

P.S. Beware that native XML parsing is problematic for Android devices. ( fine for iOS and desctop browsers ) , so JSON is a better format in the common case.

dhtmlx touch still able to process xml on Android devices, but used workaround can fail if you need to have complex xpaths for data location. ( custom xml formats )

Thanks for that info.

I still do not seem to understand how to get this to work. This is the source of the data http://

How can I use what you provided to pick a certain item to populate a list?


Check the attached sample.

            dhx.DataDriver.xml.records = "//movie";
    					{ cols:[	
    						{ view:"list", 
    							id:"mylist", url:"proxy.php", datatype:"xml",select:true,
    							template:"#name# (#type#)", select:true, type: { width: "auto" }
    					  ] }

load_list.ZIP (52.2 KB)

Stanislav - Your solution is brilliant and works perfectly. I actually wrote a php proxy prior to your response that allows cross domain loading of XML which worked though I like your solution its far simpler.

Thank you very much. Your support is on point and immediate.