This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
RE: Multiple Input Sources
- To: "'xsl-list at mulberrytech dot com'" <xsl-list at mulberrytech dot com>
- Subject: RE: Multiple Input Sources
- From: "Clementson, Bill" <Bill_Clementson at jdedwards dot com>
- Date: Wed, 7 Jun 2000 13:18:23 -0600
- Reply-To: xsl-list at mulberrytech dot com
>If you happen to be using MSXML (which still doesn't support
>the "document()" function) you can pass the parsed DOM of
>other XML sources as parameters programmatically.
Alternatively, (if you are using the technology preview of MSXML) you can
code the following script to emulate the document() function:
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:state="http://www.vbxml.com/state"
xmlns:msxsl="urn:schemas-microsoft-com:xslt"
version="1.0">
<xsl:output method="xml" omit-xml-declaration="yes"/>
<msxsl:script language="VBScript" implements-prefix=
"state">'<![CDATA[
function document(url)
set xmlDoc=createObject("MSXML2.DOMDocument")
xmlDoc.async=false
xmlDoc.load url
set document=xmlDoc
end function
']]></msxsl:script>
</xsl:stylesheet>
To retrieve a document stream into a variable you'd then use:
<xsl:variable name="doc"><xsl:copy-of
select="state:document('http://www.myServer.com/myXMLDoc.xml')"/>
This example is taken from the "Direct Add to Output Via Script in XSL
Transform" article at:
http://www.inquiry.com/techtips/xml_pro/answer.asp?pro=xml_pro&docID=4790
Hope that helps,
Bill
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list