|
Subject: [xsl] multiple tranformations in XMLDOM From: Bryan Tarantina <bryantarantina@xxxxxxxxx> Date: Wed, 17 Jul 2002 11:26:41 -0700 (PDT) |
Hey guys,
I have a small problem I am working on. Here's the
process:
source.xml + trans1.xsl -> out.xml
then:
out.xml + trans2.xsl -> out.html
This is all done with the XMLDOM in Javascript. I need
to go straight to the out.html file, so no saving
files in the interim steps. The trick: the out.xml
file actually contains html source I am treating as
XML (since it is well-formed).
Both XSL sheets have output specified as XML.
In Javascript I can create the variables and get each
transformation done separately (if I save out.xml as a
file), but I am having problems getting the second one
to work off the direct output of the first. Here's
what I have in Javascript:
var xmlDoc = new ActiveXObject("Microsoft.XMLDOM")
xmlDoc.async="false"
xmlDoc.validateOnParse="false"
xmlDoc.load("source.xml")
var xslDoc = new ActiveXObject("Microsoft.XMLDOM")
xslDoc.async="false"
xslDoc.load("trans1.xsl")
var newxmlDoc = new ActiveXObject("Microsoft.XMLDOM")
newxmlDoc.async="false"
newxmlDoc.load("out.xml")
var newxslDoc = new ActiveXObject("Microsoft.XMLDOM")
newxslDoc.async="false"
newxslDoc.load("trans2.xsl")
var htmlout = new ActiveXObject("Microsoft.XMLDOM")
htmlout.async="false"
htmlout.validateOnParse="false"
htmlout = xmlDoc.transformNode(xslDoc)
var htmloutput = new ActiveXObject("Microsoft.XMLDOM")
htmloutput.async="false"
htmloutput.validateOnParse="false"
htmloutput = htmlout.transformNode(newxslDoc)
document.write(htmloutput)
anyideas?
Bryan
__________________________________________________
Do You Yahoo!?
Yahoo! Autos - Get free new car price quotes
http://autos.yahoo.com
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
| Current Thread |
|---|
|
| <- Previous | Index | Next -> |
|---|---|---|
| Re: [xsl] How to reuse param in two, Jeni Tennison | Thread | Re: [xsl] multiple tranformations i, Mattias Konradsson |
| Re: [xsl] Assist With choose condit, Jeni Tennison | Date | [xsl] csv output - carriage return , tp001 tp |
| Month |