Question

I have numerous XML files that are organized into different directories. I need to combine them and transform the result using XSLT. So far, I have already done this except for one problem: some XML files need to be transformed first before it can be included into the result. xinclude seems to ignore the xml-stylesheet declaration.

How can i transform XML files before they are xincluded?

Regards,

[ simon.cpu ]

Was it helpful?

Solution

How is the process run? With a Makefile or something like that? In that case, add explicit calls to xsltproc before the inclusion and then xinclude the output of xsltproc.

If xsltproc can read the processing instruction (xml-stylesheet, note that I did not test that), you do not even have to indicate explicitely the stylesheet to use.

OTHER TIPS

Break it up into multiple transform calls, first prepare the xml files, then do your main transformation.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top