Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Sebastien BROUET on Mar 25, 2008 04:02
open dhtmlx forum
Browser compatibility problem with « doXPath » under IE 6 & 7

Hello,

I made a sample which makes an Ajax call, retrieves an XML file and updates the grid on the page using a custom “<action>”.

This works fine under Firefox (2.0.0.12) but not under IE 6 & 7.

I am using version dhtmlxTreeGrid_v14_Pro_70813.

The “dataProcessor.prototype.afterUpdate » makes the following call :
var atag=xml.doXPath("//data/action");
The problem lies in the method “dtmlXMLLoaderObject.prototype.doXPath” which returns nothing (an empty array) under IE, while it is not empty when running under Firefox.

When I activate the debug mode, I can see that my XML file was received correctly.
I must specify that the XML file is retrieved locally (URL like file:///C:/...).

I tried to debug the code of “dtmlXMLLoaderObject.prototype.doXPath” and could not get the docObj.selectNodes(xpathExp) to return what is expected.


Could you please help on this hot subject ?
The documentation stands that this component is compatible with IE starting from version 5.5...

Many thanks in advance,

Regards,
Sebastien BROUET
Answer posted by Support on Mar 25, 2008 04:53
Yes, such situation is possible if data was loaded from local filesystem ( the XML parser in IE doesn't fully process XML in such case )

You can
a) change the way of XML loading to http:// like URI
or
b) contact us directly at support@dhtmlx.com , we can send you latest version of dataprocessor.js which already has built in workaround for such situation.