W3C home > Mailing lists > Public > www-html@w3.org > July 2003

RE: ID and NAME tokens (CDATA problems)

From: Peter Foti (PeterF) <PeterF@SystolicNetworks.com>
Date: Tue, 15 Jul 2003 12:46:12 -0400
Message-ID: <A10A983C9DFBD4119F0300104B2EA6B726038B@ZIPPY>
To: "'Bjoern Hoehrmann'" <derhoermi@gmx.net>
Cc: "'www-html@w3.org'" <www-html@w3.org>

Bjoern Hoehrmann wrote:
>* Peter Foti (PeterF) wrote:
>>The HTML 4 recommendation states that:
>>ID and NAME tokens must begin with a letter ([A-Za-z]) and 
>may be followed
>>by any number of letters, digits ([0-9]), hyphens ("-"), 
>underscores ("_"),
>>colons (":"), and periods ("."). 
>>Thus, if a form is defined as follows:
>><form action="" name="myform">
>>   <input name="readme.txt-title">
>>   <input name="readme.txt-author">
>Please note that the name attributes in HTML are CDATA attributes not
>NAME or ID attributes, thus you could also use e.g. name="foo bar".

Indeed, you are correct.  I followed the CDATA link in the spec (from the
name attribute of the INPUT element), and then mistakenly read the ID and
NAME tokens to be the HTML 4 attributes having further constraints
(mentioned in the CDATA description).  Now that you have pointed this out,
it is quite clear.  Perhaps the difference in spacing between the list items
confused me the first time around (notice there is additional whitespace at
the end of the CDATA description, but not separating the "ID and NAME...",
"IDREF and IDREFS...", and "NUMBER..." list items).

Peter Foti
Received on Tuesday, 15 July 2003 12:31:57 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:06:04 UTC