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

Re: On id and name attributes

From: Bjoern Hoehrmann <derhoermi@gmx.net>
Date: Mon, 16 Jul 2001 14:55:20 +0200
To: "Clover Andrew" <aclover@1value.com>
Cc: <www-html@w3.org>, www-html-editor@w3.org
Message-ID: <5go5ltgn4d5f1qfden05erj3gv4ufanflq@4ax.com>
* Clover Andrew wrote:
>Bjoern Hoehrmann <derhoermi@gmx.net> wrote:
>
>> HTML 4.01 section 12.2.3 states: "The id and name attributes
>> share the same name space". Is this true for _all_ name
>> attributes?
>
>No. Each form has its own namespace for control names, and each
>applet has its own scope for parameters.

Ok, Erratum #1.

>>The same section states further:
>>
>>  "It is permissible to use both [id and name] attributes to specify an
>>   element's unique identifier for the following elements: A, APPLET,
>>   FORM, FRAME, IFRAME, IMG, and MAP".

And even further:

    "When both attributes are used on a single element, their values
     must be identical."

>> Why does this not apply to BUTTON, TEXTAREA, SELECT, INPUT,
>> OBJECT and PARAM?

Erratum #2, if the name and id attributes for those elements don't share
the same namespace, is so no reason why one must not use both
attributes. If one uses both attributes, it doesn't matter if they have
the same value or not.

>> Why 'id = name'? It is defined as ID in the DTD
>
>True! Is this a mistake?

I think so, Erratum #3.

x'posted to www-html-editor@w3.org.
-- 
Björn Höhrmann { mailto:bjoern@hoehrmann.de } http://www.bjoernsworld.de
am Badedeich 7 } Telefon: +49(0)4667/981028 { http://bjoern.hoehrmann.de
25899 Dagebüll { PGP Pub. KeyID: 0xA4357E78 } http://www.learn.to/quote/
Received on Monday, 16 July 2001 08:56:24 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 27 March 2012 18:15:49 GMT