• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1018
  • Last Modified:

XML/XSL/HTML: Transformation of multiple XML documents to (cross-browser) HTML/XHTML documents

Hi all,

we plan to put a 500 records product database to a webserver and a product CD/DVD.
The records are in XML format (XML 1...500).

Our understanding (roughly) is to:
1. load XML
2. load XSL
3. transform to HTML/XHTML
4. deploy to webserver and optical media (by using DWebPro)

Can you give us a guideline on how to develop such a project?
Can XSL process multiple XML sequentially?
Can XSL write/split the input XML to different HTML (each product seperate HTML)?
How to generally process (open, read, ...) files with XSL?
How to generally SEARCH XML documents or other sources (TXT) with XSL?

Thanks.
0
go4java
Asked:
go4java
  • 2
  • 2
1 Solution
 
Geert BormansCommented:
Hi go4java,

> Can you give us a guideline on how to develop such a project?
take a test XML, develop your XSLT (use an IDE for that, www.oxygenxml.com eg.)
test the XSLT with a larger subset of your data, decide on an architecture (for looping over multiple files, passing environment parameters such as dates etc...)
set up the surrounding architecture and run....

> Can XSL process multiple XML sequentially?
you would run the same XML process in a batch operation on multiple files
this is better organised in your surrounding architecture... batch file, ASP, Java program,...

> Can XSL write/split the input XML to different HTML (each product seperate HTML)?
you can do that in XSLT2.0.
Some processors have an extension to do that in XSLT1.0 (eg. Saxon)

>How to generally process (open, read, ...) files with XSL?
this can be command line (using xalan or msxsl eg.) or this can be done from withing code (JSP, ASP, java, C#, javascript, Python,...)

> How to generally SEARCH XML documents or other sources (TXT) with XSL?
in one file, use XPath, in multiple files, develop a routine to search multiple files outside XSLT, use XPath to search inside a particulare file

hope this helps
Cheers!
0
 
go4javaAuthor Commented:
Thanks, Gertone.

"> Can XSL write/split the input XML to different HTML (each product seperate HTML)?
you can do that in XSLT2.0.
Some processors have an extension to do that in XSLT1.0 (eg. Saxon)

=> do you have a sample code
0
 
jkmyoungCommented:
http://saxon.sourceforge.net/saxon6.5.5/extensions.html#saxon:output

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:saxon="http://icl.com/saxon">
<xsl:template match="/">
   
   1st document output

  <saxon:document href="output2.html"
      2nd file output
  </saxon:document>
</xsl:template>

</xsl:stylesheet>
xstl 1.1 uses <xsl:document>
xslt 2.0 uses <xsl:result-document>
0
 
go4javaAuthor Commented:
Thanks for the SAXON hint.
Meanwhile I read that Xalan-J/EXSLT is the 'standard' for such kind of operations...
Can you confirm that XALAN and EXSLT fits in Apache TOMCAT framework (J2EE engine)?!
0
 
Geert BormansCommented:
> Can you confirm that XALAN and EXSLT fits in Apache TOMCAT framework (J2EE engine)?!

yep, no problem, it is the default install
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now