florian wrote:
hi!
i have following situation and would like to know whats the
best practice for it:
i have:
- xml document describing some data
(e.g. <foo><name>john</name></foo>)
- xml document describing an abstract webpage
(e.g. <page><header /><box /></page>)
the abstract webpage-xml gets transformed into concret
implementations (e.g. html) via xslt, also some information
out of the data-xml should be taked via xslt.
the question is: whats the best way to do that? just
use the data xml doc as the xml doc used for the xsl
transformation, and place the webpage-xml in the xslt template
matching the root node? but then?
thanks alot for any tip!
ciao!
florian
You are not providing too much information for a conrete solution. However
some general ideas are:
1st) You could have the stylesheet for the template document to import
the data specific stylesheet
and then use the "document()" function to process the data of the
respective XML file.
That requires that the processing of the layout and data xml ara
performed at the same time.
2nd) Another approach would be to use the layout XML to generate a
stylesheet that will
process the data xml document.
However, I'm sure that if you give more info people will be able to
provide more info.
Mike.
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list