A
Adam
Hi
I have some large XML files and need to produce a website from them,
but they will need cutting up into smaller sections, and to produce
navigation between them all.
For example:
doc1.xml wants to be cut up in to:
doc1_a.xml
doc1_b.xml
doc1_c.xml
doc1_d.xml
The XML is simple there are only 12 tags so what I am after is a way
to count characters to say 500, find the closest <aheader> tag cut
above it, and produce an xml file, then count from that <Aheader> tag
and do the same again?
i.e.
doc1.xml =
<root>
<aheader>Blar…Blarr…</aheader>
<bheader>Blar…Blarr…</bheader>
<bodytext>Blar…Blarr…</ bodytext >
< bodytext >Blar…Blarr…</ bodytext >
< bodytext >Blar…Blarr…</ bodytext >
<quote>Blar…Blarr…</ quote >
< bodytext >Blar…Blarr…</ bodytext >
<!-----------Cut here------------this is not in the XML>
<aheader>Blar…Blarr…</aheader>
< bheader >Blar…Blarr…</ bheader >
< bodytext >Blar…Blarr…</ bodytext >
< bodytext >Blar…Blarr…</ bodytext >
</root>
-------------------------------------------------
and produce 2 files like this:
doc1_a.xml=
<root>
<aheader>Blar…Blarr…</aheader>
<bheader>Blar…Blarr…</bheader>
<bodytext>Blar…Blarr…</ bodytext >
< bodytext >Blar…Blarr…</ bodytext >
< bodytext >Blar…Blarr…</ bodytext >
<quote>Blar…Blarr…</ quote >
< bodytext >Blar…Blarr…</ bodytext >
</root>
doc1_b.xml=
<root>
<aheader>Blar…Blarr…</aheader>
< bheader >Blar…Blarr…</ bheader >
< bodytext >Blar…Blarr…</ bodytext >
< bodytext >Blar…Blarr…</ bodytext >
</root>
Can this be done? And how, I know a bit of XSL, is there a program
that does this already?
Also when this is done, I need a navigation page to understand the
structure of my files?
I have a friend that says this can be done in Microsoft C sharp? But I
thought that was music (joke)
Thanks for any help
I have some large XML files and need to produce a website from them,
but they will need cutting up into smaller sections, and to produce
navigation between them all.
For example:
doc1.xml wants to be cut up in to:
doc1_a.xml
doc1_b.xml
doc1_c.xml
doc1_d.xml
The XML is simple there are only 12 tags so what I am after is a way
to count characters to say 500, find the closest <aheader> tag cut
above it, and produce an xml file, then count from that <Aheader> tag
and do the same again?
i.e.
doc1.xml =
<root>
<aheader>Blar…Blarr…</aheader>
<bheader>Blar…Blarr…</bheader>
<bodytext>Blar…Blarr…</ bodytext >
< bodytext >Blar…Blarr…</ bodytext >
< bodytext >Blar…Blarr…</ bodytext >
<quote>Blar…Blarr…</ quote >
< bodytext >Blar…Blarr…</ bodytext >
<!-----------Cut here------------this is not in the XML>
<aheader>Blar…Blarr…</aheader>
< bheader >Blar…Blarr…</ bheader >
< bodytext >Blar…Blarr…</ bodytext >
< bodytext >Blar…Blarr…</ bodytext >
</root>
-------------------------------------------------
and produce 2 files like this:
doc1_a.xml=
<root>
<aheader>Blar…Blarr…</aheader>
<bheader>Blar…Blarr…</bheader>
<bodytext>Blar…Blarr…</ bodytext >
< bodytext >Blar…Blarr…</ bodytext >
< bodytext >Blar…Blarr…</ bodytext >
<quote>Blar…Blarr…</ quote >
< bodytext >Blar…Blarr…</ bodytext >
</root>
doc1_b.xml=
<root>
<aheader>Blar…Blarr…</aheader>
< bheader >Blar…Blarr…</ bheader >
< bodytext >Blar…Blarr…</ bodytext >
< bodytext >Blar…Blarr…</ bodytext >
</root>
Can this be done? And how, I know a bit of XSL, is there a program
that does this already?
Also when this is done, I need a navigation page to understand the
structure of my files?
I have a friend that says this can be done in Microsoft C sharp? But I
thought that was music (joke)
Thanks for any help