W3C home > Mailing lists > Public > xproc-dev@w3.org > August 2012

RE: Adding <!DOCTYPE html> using XProc/Calabash

From: Geert Josten <geert.josten@dayon.nl>
Date: Fri, 17 Aug 2012 10:48:08 +0200
Message-ID: <e4781e893370cf4bc2bd75fef9c1e512@mail.gmail.com>
To: Romain Deltour <rdeltour@gmail.com>, XProc Dev <xproc-dev@w3.org>
Hmm right, you mean that the output specs in the xslt is being ignored,
and any output from p:xslt treated as xml? Makes sense..

-----Oorspronkelijk bericht-----
Van: Romain Deltour [mailto:rdeltour@gmail.com]
Verzonden: vrijdag 17 augustus 2012 10:43
Aan: XProc Dev
Onderwerp: Re: Adding <!DOCTYPE html> using XProc/Calabash

I don't think that's it. It's just that the XSLT advised by Jim does not
produce an XML document, if I understand correctly. The doctype output is
part of the serialization, so with the xsl:text you have an XDM that does
not represent a single XML document and it cannot be used with the
standard p:xslt XProc step.

As far as I know there is no standard way to serialize a result with the
default HTML5 doctype. It would need an extension step.

Romain.


On 17 août 2012, at 08:39, Geert Josten <geert.josten@dayon.nl> wrote:

> Probably because you have a step after the xslt that is expecting XML,
> not text/html? There should be tricks to force it into treating it as
> text or binary.. i think.. :P
>
> -----Oorspronkelijk bericht-----
> Van: David Cramer [mailto:david@thingbag.net]
> Verzonden: vrijdag 17 augustus 2012 6:14
> Aan: James Fuller
> CC: Zearin; XProc Dev
> Onderwerp: Re: Adding <!DOCTYPE html> using XProc/Calabash
>
> On 08/16/2012 04:00 PM, James Fuller wrote:
>> one hack is something like
>>
>> <?xml version="1.0" encoding="utf-8"?> <xsl:stylesheet version="1.0"
>> xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
>>  <xsl:output method="html" encoding="utf-8" indent="yes" />
>>
>>  <xsl:template match="/">
>>    <xsl:text disable-output-escaping='yes'>&lt;!DOCTYPE
> html></xsl:text>
>>    <html>
>>    </html>
>>  </xsl:template>
>>
>> </xsl:stylesheet>
>>
>> pipe your final html through an xslt step.
>
> Thanks Jim. Actually, I've tried that
> and get:
>
> com.xmlcalabash.core.XProcException: XD0001
>
> David
>
Received on Friday, 17 August 2012 08:48:56 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 17 August 2012 08:48:56 GMT