This is the mail archive of the
docbook-apps@lists.oasis-open.org
mailing list .
Re: Re: condition attribute + XSL + doctype declara tion
- From: Bob Stayton <bobs at caldera dot com>
- To: "Bradford, Denis" <denisb at rational dot com>, docbook-apps at lists dot oasis-open dot org
- Date: Thu, 14 Feb 2002 23:02:36 -0800
- Subject: Re: DOCBOOK-APPS: Re: condition attribute + XSL + doctype declara tion
- References: <3906C56A7BD1F54593344C05BD1374B1053EB4C2@SUS-MA1IT01>
On Thu, Feb 14, 2002 at 04:47:56PM -0500, Bradford, Denis wrote:
> >From: Norman Walsh <ndw@nwalsh.com>
> >To: docbook-apps@lists.oasis-open.org
> >Date: Sun, 15 Jul 2001 17:43:47 -0400
> >--------------------------------------
> >/ "M.-A. DARCHE" <ma.darche@free.fr> was heard to say:
> >| I had to add
> >| doctype-public="-//OASIS//DTD DocBook XML V4.1.2//EN"
> >| doctype-system="http://www.oasis-open.org/docbook/xml/4.0/docbookx.dtd"
> >| in <xsl:output> because the doctype declaration
> >| <!DOCTYPE HTML PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
> >| "http://www.oasis-open.org/docbook/xml/4.0/docbookx.dtd">
> >| is being lost in the process.
> >
> >Yep.
>
> That takes care of the DTD declaration, but I'm losing everything else in
> the subset, too! Here's before and after running profile.xsl:
>
> source.xml
> ----------
> <?xml version="1.0" encoding="utf-8"?>
> <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
> "docbookx.dtd" [
> <!ENTITY comparingxml SYSTEM "comparingxml.xml">
> <!ENTITY usingxdm SYSTEM "usingxdm.xml">
> <!ENTITY glossary SYSTEM "xmldiffmrg_gloss.xml">
> <!ENTITY xdm-diffwin1 SYSTEM "xdm-diffwin1.gif" NDATA GIF>
> ]>
> <book>
> ...
>
> profiled.xml
> ------------
> <?xml version="1.0" encoding="utf-8"?>
> <!DOCTYPE book
> PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" "docbookx.dtd">
> <book print.status="draft">
> ...
>
> The only workaround I can think of is some non-XSL pre- or post-processing.
> Is there a better way?
There was a recent related discussion about XSLT not
being able to output internal subsets:
http://sources.redhat.com/ml/docbook-apps/2002-q1/msg00621.html
The XSLT spec doesn't support it, so unless someone
has a creative solution, it looks like an
extension would be required to pass through an
internal subset.
--
Bob Stayton 400 Encinal Street
Publications Architect Santa Cruz, CA 95060
Technical Publications voice: (831) 427-7796
Caldera International, Inc. fax: (831) 429-1887
email: bobs@caldera.com