Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Linking Multiple XML files in a single xsl or html file

Status
Not open for further replies.

goofy78270

Technical User
Jul 24, 2007
38
0
0
US
I have multiple XML files that are created by different departments that I would like to combine in a single webpage, but I am unsure how to link multiple xml documents in either the xsl or html files.

Any help would be greatly appreciated.
 
From what I see, the xsl:import and xsl:include only mention xsl files. Can xml be imported into the xsl or do I need to create seperate xsl files for each?

Could I load multiple xml files into the html using some javascript such as:

Code:
<script type="text/javascript">
// Load XML 
var xml = new ActiveXObject("Microsoft.XMLDOM")
xml.async = false
xml.load("*.xml")
// Load XSL
var xsl = new ActiveXObject("Microsoft.XMLDOM")
xsl.async = false
xsl.load("Myxsl.xsl")
// Transform
document.write(xml.transformNode(xsl))
</script>


 
No, not wildcard like that. What does the 2nd post have to do with the 1st post under whatever interpretation of normal english, that I am not native to.
 
Sorry to sound defensive, but I asked how can I combine multiple xml files into a single webpage.

1. Would it be easier to load each xml into the javascript and then load the single xsl and transform, as attempted with the previous script?
2. Would it be easier to create seperate xsd files for each xml and then import those into a master xsl file?
3. Is there another solution that will work better?

From you limited comment, for xsl:import and xsl:include, the information I found on these options only referenced an xsl file being imported or included and not xml which was my question.

Link 1 - Link 2 - Link 3 -
As far as the normacy or english, I was offering a solution that I was currently working on since I apparently did not understand you limited solution.
 
I don't prepare to spend more time than those and for those who ask care to spend asking.
 
Can you please clarify your suggestion or provide an example as the information I found states "The <xsl:import> element is a top-level element that is used to import the contents of one style sheet into another" and "The <xsl:include> element is a top-level element that includes the contents of one style sheet into another"? Since the xml file is not a stylesheet, I am unsure how this would help.

I am looking to combine xml files into a single page, not xsl files.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top