cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joel McConaughy <joelmcconau...@gmail.com>
Subject Re: 2.1.12 and html5
Date Wed, 05 Jun 2013 14:52:41 GMT
Peter,

Here's what I do which seems to work fine:

<map:serializers>
<map:serializer name="html5" mime-type="text/html"
src="org.apache.cocoon.serialization.HTMLSerializer">
<doctype-system>about:legacy-compat</doctype-system>
<encoding>UTF-8</encoding>
<omit-xml-declaration>true</omit-xml-declaration>
</map:serializer>
</map:serializers>


<map:match pattern="internal/**_jx.html">
<map:generate type="jx" src="jx/pages/{1}_jx.xml"/>
<map:serialize type="html5">
</map:serialize>
</map:match>

Joel


On Wed, Jun 5, 2013 at 7:41 AM, Peter Sparkes <peter@didm.co.uk> wrote:

>  Thank you Cédric and Thorsten
>
> However, I still can't get it working. Could you, please explain what I
> have to put in my sitemap etc.
>
> Thank you
>
> Peter
>
>
> On 05/06/2013 10:18, Cédric Damioli wrote:
>
> Hi,
>
> The XHTMLSerializer Francesco was referring to is not the org.apache.cocoon.serialization.XMLSerializer
> of your sample, but the org.apache.cocoon.components.serializers.XHTMLSerializer
> from the serializers block, which is another implementation of XHTML
> serialization.
>
> Regards,
> Cédric
>
>  On 05/06/2013 10:03, Thorsten Scherler wrote:
>
> http://mail-archives.apache.org/mod_mbox/cocoon-cvs/201211.mbox/%3C20121122234557.250DA2388A68@eris.apache.org%3E
>
> ...
>
> +        } else if ("xhtml5".equalsIgnoreCase(doctype)) {
> +            this.doctype_default = XHTML5_DOCTYPE;
> ...
>
>
> <serializer class="org.apache.cocoon.components.serializers..." ... >
>    <doctype-default>xhtml5</doctype-default>
>  </serializer>
>
>
> HTH
>
> salu2
>
>  Le 05/06/2013 07:15, Peter Sparkes a écrit :
>
> Hi Francesco ,
>
> I can't get the XHTML serializer to produce html5, the sitemap.xmap has:
>
> <map:serializer logger="sitemap.serializer.xhtml" mime-type="text/html"
> name="xhtml" pool-max="${xhtml-serializer.pool-max}"
> src="org.apache.cocoon.serialization.XMLSerializer">
>            <!--+
>           | You can choose from Strict, Transitional, or Frameset XHTML.
>           | For Strict XHTML set doctype to:
>           |   <doctype-public>-//W3C//DTD XHTML 1.0
> Strict//EN</doctype-public>
>           |   <doctype-system>
> http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd</doctype-system>
>           | For Transitional XHTML set doctype to:
>           |   <doctype-public>-//W3C//DTD XHTML 1.0
> Transitional//EN</doctype-public>
>           |   <doctype-system>
> http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd</doctype-system>
>           | For Frameset XHTML set doctype to:
>           |   <doctype-public>-//W3C//DTD XHTML 1.0
> Frameset//EN</doctype-public>
>           |   <doctype-system>
> http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd</doctype-system>
>           |
>           | Default XHTML doctype in Cocoon is XHTML Strict. If you want
> to use more than one
>           | XHTML DTD simultaneously, you can define several XHTML
> serializers.
>           +-->
>                 <doctype-public>-//W3C//DTD XHTML 1.0
> Strict//EN</doctype-public>
>                 <doctype-system>
> http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd</doctype-system>
>                 <encoding>UTF-8</encoding>
>      </map:serializer>
>
>  I have tried experimenting with various values in <doctype-public> and
> <doctype-system> but can't get
>
> <!DOCTYPE html>
> <html>
> <head>
>
> Regards
>
> Peter
>
> On 04/06/2013 08:18, Francesco Chicchiriccò wrote:
>
> On 03/06/2013 19:19, Peter Sparkes wrote:
>
> Hi
>
> Does 2.1.12 have a html5 serializer
>
>
> Yes: XHTML serializer can handle HTML5 doctype -
> https://issues.apache.org/jira/browse/COCOON-2310
>
> Regards.
>
> --
> Francesco Chicchiriccò
>
> ASF Member, Apache Syncope PMC chair, Apache Cocoon PMC Memberhttp://people.apache.org/~ilgrosso/
>
>
>
> --
> Cédric Damioli
> Ametys CMShttp://www.ametys.orghttp://www.anyware-services.com
>
>
>


-- 
Joel McConaughy
206-300-4732
joelmcconaughy@gmail.com

Mime
View raw message