On Tue, 12 Jun 2012 21:50:15 +0100, Hisateru Tanaka
In another branch I started to let PHPTAL allow using with illegal
Thanks for fixing empty elements and HTML5 attributes!
I think the namespace fix needs to handle some more cases:
must be output in HTML5 mode as:
since that's a proper XHTML input from XML/DOM perspective. That's why the
code was ignoring prefixes.
I wouldn't mind if:
was output as:
although it saddens me that's needed only for Google's invalid markup and
I'm not so sure about xmlns attributes. The "http://www.w3.org/1999/xhtml"
declaration is certainly not needed in HTML5. I think it may be better to
omit other xmlns attributes too to avoid giving false impression that
HTML5 has namespaces. It only has tags with invalid ":" character in them
and ignores xmlns attributes for compatibility with "polyglot" XHTML
documents (but HTML5 mode is inappropriate for polyglot documents).
Even in HTML5 output mode PHPTAL still is supposed to parse input as XML.
As long as TAL claims to be XML-based language I think it should follow
XML rule and require namespace declarations.
Ignoring of namespace declarations would be appropriate if PHPTAL had
HTML5 *input* mode (parse HTML5 and output it as either HTML5 or XHTML).
regards, Kornel Lesiński
PHPTAL mailing list