[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Handling invalid HTML
From: |
Jonathan Yavner |
Subject: |
Handling invalid HTML |
Date: |
Tue, 18 Oct 2005 11:05:55 -0400 |
User-agent: |
KMail/1.6.2 |
Juri Linkov writes:
> 1. The valid string delimiter for HTML attribute values is the
> quotation character. However, some HTML files on the Web use
> apostrophes, e.g.
> <meta http-equiv='Content-Type' content='text/html; charset=UTF-8'>
> The program that generates such non-standard meta headers is
> identified as 'Microsoft DHTML Editing Control' (no surprise).
http://www.w3.org/TR/html4/intro/sgmltut.html#h-3.2.2
"By default, SGML requires that all attribute values be delimited
using either double quotation marks (ASCII decimal 34) or single
quotation marks (ASCII decimal 39). ... In certain cases, authors
may specify the value of an attribute without any quotation marks."
In XHTML the no-marks case was eliminated, but the use of 'apostrophes'
is still valid. There are many complaints one can make about
Microsoft, but this isn't one of them.
--Jonathan