[webkit-dev] JavaScript for XML with XSL
Mark Rowe
mrowe at apple.com
Sun Feb 17 07:29:10 PST 2008
Pierre,
On 18/02/2008, at 02:10, Pierre Bernard wrote:
> function loadXMLDoc(fname)
> {
> var xmlDoc;
> xmlDoc=document.implementation.createDocument("","",null);
>
> xmlDoc.async=false;
> xmlDoc.load(fname);
> return(xmlDoc);
> }
The code fails with the following error:
Value undefined (result of expression xmlDoc.load) is not object.
http://www.w3schools.com/xsl/tryit_view.asp?filename=cdcatalog (line 22)
The Document.load method being called here appears to be part of the
June 2003 working draft of DOM Level 3 Load and Save Specification (http://www.w3.org/TR/2003/WD-DOM-Level-3-LS-20030619/
), but has since been removed from that specification. Firefox, Opera
and Internet Explorer appear to implement this method in some form.
WebKit's lack of support for this method is tracked by <http://bugs.webkit.org/show_bug.cgi?id=9063
>.
If you change your code to load the XML document via a method that
WebKit does support do you have better luck with processing it via XSL?
- Mark
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2413 bytes
Desc: not available
Url : http://lists.webkit.org/pipermail/webkit-dev/attachments/20080218/edcc59da/attachment.bin
More information about the webkit-dev
mailing list