ca9mbu at eos.sunderland.ac.uk
Wed Jan 15 14:53:23 PST 2003
"Gerard Beekmans" <gerard at linuxfromscratch.org> wrote in message
news:200301151538.21779.gerard at linuxfromscratch.org...
> On January 15, 2003 03:24 pm, Matthew Burgess wrote:
> > xsltproc --xinclude --output lfsexample.html lfs2html.xsl lfsexample.xml
> > Hope this helps.
> Bingo that works. I had to add the DOCTYPE line to the include.xml file
> that was it.
> Is there a way to make DOCTYPE being inherited from the parent doc?
> The included xml files right now aren't full xml files, there's no <?xml?>
> header, or a doctype. Just a straight include. Kind of like a "source"
> function in bash.
> That way we can write quick xml files without having to make them Fully
> Qualified XML Files (FQXMLF anybody?)
> But, it's not such a big deal. We are only talking about two lines on top
> every file. That isn't a big deal. But if we were to change the doctype in
> the parent file we'd have to make the same change to every other xml file.
> That'd be more work (though a recursive sed would help, but it'd be nicer
> that weren't necessary).
I'm not sure quite what is going on here?
--- begin lfsexample.xml ---
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="include.xml"/>
--- end lfsexample.xml ---
--- index.xml ---
--- index.xml ---
and at this point xsltproc complains because of the missing <?xml> and
doctype within index.xml? If so you may want to try changing the XInclude
tag to something like:
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="include.xml"
This should tell xsltproc not to try and validate include.xml (as strictly
speaking it isn't a valid XML file). This shouldn't affect xsltproc's
validation of the resultant xml file though.
Hope this helps,
Unsubscribe: send email to listar at linuxfromscratch.org
and put 'unsubscribe lfs-book' in the subject header of the message
More information about the lfs-book