cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Legg" <david.l...@searchevent.co.uk>
Subject Re: How do you generate 4.01 strict HTML? - SOLVED
Date Wed, 09 Nov 2005 23:58:03 GMT
> Anyone know the secret to generating compliant 4.01 strict from Cocoon?

OK... I solved my own problem.  So, for the record...

My xslt transformation file (which originated from the Cocoon welcome.xslt 
file) had the following line near the top: -

    <xsl:stylesheet version="1.0" 
xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 
xmlns="http://www.w3.org/1999/xhtml">

That default namespace declaration on the end of the line was interfering 
with the HTML serializer and preventing it from generating true HTML.  I 
removed it and changed the 'html' serializer declaration in the sitemap 
to: -

    <map:serializer logger="sitemap.serializer.html"
         mime-type="text/html"
         name="html"
         src="org.apache.cocoon.serialization.HTMLSerializer">
      <doctype-public>-//W3C//DTD HTML 4.01//EN</doctype-public>
      <doctype-system>http://www.w3.org/TR/html4/strict.dtd</doctype-system>
    </map:serializer>

Now the page is correctly being output as strict HTML 4.01 with no 
namespaces or '/' characters in <br> tags for example.

Regards,
David Legg 



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message