Issue Type: New Feature Created: 2009-08-29T07:40:33.000+0000 Last Updated: 2009-12-18T14:03:46.000+0000 Status: Resolved Fix version(s): - 1.10.0 (27/Jan/10)
Reporter: Pádraic Brady (padraic) Assignee: Andy Fowler (andyfowler) Tags: - Zend_View
Related issues: - ZF-7724
Attachments: - html5-support-charset-meta.diff
HTML 5 introduces support for the "charset" meta tag to replace the HTML 4 http-equiv "Content-Type". Support for this is not possible with Zend_View_Helper_HeadMeta (that I can tell). It can be introduced by adding a new setCharset() method for the helper and introducing some changes to enforce that a content attribute is not required so long as a) the doctype is HTML5 and b) its a meta element of type "charset". Additionally, HTML 5 drops support for the "scheme" attribute (passed as modifiers in many methods).
Adding at least the charset meta support is not a huge problem. See the attached patch in the next comment. It would be great to see HTML 5 support in other areas make it into Zend_View and Zend_Form (e.g. the new input types). If there's a need for some help here, let me know. I've marked this issue as a minor new feature - if another category is more appropriate feel free to edit. HTML 5 support overall would be major in my opinion ;).
Posted by Pádraic Brady (padraic) on 2009-08-29T07:42:20.000+0000
Patch to introduce support for the HTML 5 charset meta element.
Posted by Pádraic Brady (padraic) on 2009-08-29T12:01:20.000+0000
The patch can be further modified to also add a condition detecting a XHTML5 doctype (same as HTML5 except it prefers closing all tags as per typical XHTML practice, and any other XHTML behaviour still supported by an XHTML serialisation of HTML5). I've linked to the issue in question.
Posted by Andy Fowler (andyfowler) on 2009-12-17T11:59:49.000+0000
adds a patch quite similar to padraic's, but moves html5 checking back to the doctype via an isHtml5() method (just like isXhtml()). includes documentation and unit tests for everything :)
Posted by Matthew Weier O'Phinney (matthew) on 2009-12-18T14:03:45.000+0000
Patch applied in trunk, and will release with 1.10 -- thanks!
Have you found an issue?
See the Overview section for more details.