Re: XHTML 1.0 Errata

Hello,

I'm very sorry for my late response.

Andrew A Gullans <andrewgullans@juno.com> wrote:

> I'm not sure if this is errate or not.  I'm tempted to think it's correct
> use of nested quotation, but it seems strange.
> 
> On page 26, Appendix entry C.9 (Character Encoding) of the XHTML 1.0
> specification ../TR/1999/PR-xhtml1-19990824 (xhtml1.pdf), the following
> declaration is given:
> 
> <meta http-equiv="Content-type" content='text/html; charset="UTF-8"' />
> 
> Note the single quote ( ' ) before text/html and after "UTF-8".  Is this
> proper?

It is proper, as well as the following:

  <meta http-equiv="Content-type" content="text/html; charset=UTF-8" />

> Should the quotes around text/html surround the charset argument
> as well?  Is it a property of meta tags that all attributes and arguments
> after the http-equiv="huh" part be nested in quotes?

Syntax of contents of the http-equiv values are defined in the HTTP
specification.  "3.7 Media Types" of RFC 2616 (a.k.a. HTTP/1.1)
defines the syntax of media types in HTTP as follows:

       media-type     = type "/" subtype *( ";" parameter )
       type           = token
       subtype        = token

       parameter               = attribute "=" value
       attribute               = token
       value                   = token | quoted-string

Thus, an attribute value may be a token or a quoted-string.  HTTP
uses MIME-like format, and "5.1.  Syntax of the Content-Type Header
Field" of RFC 2045 (a.k.a. MIME Part One) notes as follows:

   Note that the value of a quoted string parameter does not include the
   quotes.  That is, the quotation marks in a quoted-string are not a
   part of the value of the parameter, but are merely used to delimit
   that parameter value.  In addition, comments are allowed in
   accordance with RFC 822 rules for structured header fields.  Thus the
   following two forms

     Content-type: text/plain; charset=us-ascii (Plain text)

     Content-type: text/plain; charset="us-ascii"

   are completely equivalent.

Regards,
-- 
Masayasu Ishikawa / mimasa@w3.org
W3C - World Wide Web Consortium

Received on Saturday, 17 March 2001 06:23:38 UTC