W3C home > Mailing lists > Public > www-validator@w3.org > February 2010

Re: Custom attributes in HTML elements

From: Leif Halvard Silli <xn--mlform-iua@xn--mlform-iua.no>
Date: Sat, 13 Feb 2010 02:00:58 +0100
To: "Michael A. Peters" <mpeters@mac.com>
Cc: "Jukka K. Korpela" <jkorpela@cs.tut.fi>, Claudia Murialdo <cmurialdo@gmail.com>, www-validator@w3.org
Message-ID: <20100213020058890172.51c71f2b@xn--mlform-iua.no>
Michael A. Peters, Fri, 12 Feb 2010 03:57:20 -0800:
> Leif Halvard Silli wrote:
>> Leif Halvard Silli, Fri, 12 Feb 2010 11:31:58 +0100:
>>> Jukka K. Korpela, Fri, 12 Feb 2010 06:17:49 +0200:
>>>> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
>>>>   "http://www.w3.org/TR/html4/loose.dtd"
>>>>   [ <!ATTLIST P foo         CDATA     #IMPLIED ]>

>> It found out that it should have been ">]>" at the end:
>> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
>> [<!ATTLIST P foo CDATA #implied>]>
>> And I also get the problem with "]>" displaying in the text.
> The only way to solve that is to send the page with the mime type 
> application/xml+xhtml - which of course requires the page be proper 
> xml - which means you need to use an XHTML doctype (and proper xhtml)
> Been there, done that, breaks the page in IE.
> Only way around it is to use a custom doctype.

Well, it can be done with HTML4 also! Here is a first attempt at a HTML 
4.01 Transitional page, which validates and which have two custom 
attributes via DTD and no superfluous "]>" in the body:


Of course, the code is what some would call hideous. (There are no 
explanations at the moment.) And even if I refine it later, it will no 
doubt will not be as elegant as it should, as long as Web browsers 
behave as they do.
leif halvard silli

Received on Saturday, 13 February 2010 01:01:36 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 1 March 2016 14:18:00 UTC