importStylesheet changes in 1.9 ?
Fabrice Desré <[email protected]> Fri, 23 Nov 2007 07:58:18 -0600
| Newsgroups | gmane.comp.mozilla.devel.layout.xslt |
|---|---|
| Message-ID | <[email protected]> |
Hello,
When porting a FF 2.0 to xulrunner 1.9, I can't get basic XSLT
functionnality to work anymore. the nsIXSLTProcessor.importStylesheet()
call is failing with the following message :
"Component returned failure code: 0x80600001
[nsIXSLTProcessor.importStylesheet]" nsresult: "0x80600001 (<unknown>)
Here's a very simple function I wrote to isolate the problem.
function init() {
try {
var src = document.implementation.createDocument("", "", null);
src.async = false;
src.load("http://localhost/~ifda7415/index.xml");
var xsl = document.implementation.createDocument("", "", null);
xsl.async = false;
xsl.load("http://localhost/~ifda7415/launcher.xsl");
xsltproc = new XSLTProcessor();
xsltproc.importStylesheet(xsl);
var res = xsltproc.transformToFragment(src, document);
dump(res);
} catch (e) { dump(e)}
}
I'm sure the issue is not with the index.xml and launcher.xsl files,
since running xsltproc (from libxslt) with the same URLs works fine, and
this also works with FF 2.0
Any hints appreciated !
Fabrice