[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

RE: [xsl] Fwd: split 1 xml file to N other xml files


Subject: RE: [xsl] Fwd: split 1 xml file to N other xml files
From: "Josh Canfield" <Josh.Canfield@xxxxxxxxxxxx>
Date: Tue, 27 Jan 2004 08:30:23 -0800

The Xalan way to solve it is with the redirect extension found here:
http://xml.apache.org/xalan-j/extensionslib.html#ex-redirect

or the EXSL way would be to use the exsl:document extension found here:
http://www.exslt.org/exsl/elements/document/index.html

Hope this helps,
Josh
-----Original Message-----
From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx
[mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx]On Behalf Of
memala@xxxxxxx
Sent: Tuesday, January 27, 2004 3:16 AM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Cc: memala@xxxxxxx
Subject: [xsl] Fwd: split 1 xml file to N other xml files


Hi,
I´m new to xml and I´m not sure if this is the correct mailing list to ask.
My problem is the following (I already searched in Google etc. and couldn´t
find a suitable answer.):
The entire navigation of my homepage is in a single large xml file (it is
esier to maintain).  I want "xalan" (from apache ant http://ant.apache.org)
to
split it into single files.
Then this  single xml files are tranformed to xhtml. I already tried to
solve this with perl but it gets really complicated.
What is the  "xml way" to solve this ?

Thanks and regards 
Emal Alekozai

Example (to make my problem clear):
=====================
<!--Input: navigation.xml-->
<navigation/>
<menu filename="fileA.xml" link="fileA.xhtml" label="A">
       <submenu link="A1.xhtml">Link to A1</submenu>
       <submenu link="A2.xhtml">Link to A2</submenu>
</menu>
<menu filename="fileB.xml" link="fileB.xhtml" label="B">
       <submenu link="B1.xhtml">Link to B1</submenu>
       <submenu link="B2.xhtml">Link to B2</submenu>
</menu>
</navigation>



<!--Output: fileA.xml-->
<navigation/>
<menu link="fileA.xhtml" label="A">
       <submenu link="A1.xhtml">Link to A1</submenu>
       <submenu link="A2.xhtml">Link to A2</submenu>
</menu>
<menu link="fileB.xhtml" label="B">
</menu>
</navigation>



<!--Output: fileB.xml-->
<navigation/>
<menu link="fileA.xhtml" label="A">
</menu>
<menu link="fileB.xhtml" label="B">
       <submenu link="B1.xhtml">Link to B1</submenu>
       <submenu link="B2.xhtml">Link to B2</submenu>
</menu>
</navigation>

-- 
+++ GMX - die erste Adresse für Mail, Message, More +++
Bis 31.1.: TopMail + Digicam für nur 29 EUR http://www.gmx.net/topmail


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



Current Thread
Keywords
xml