- From: Jewett, Jim J <jim.jewett@eds.com>
- Date: Thu, 22 Jan 2004 09:38:38 -0500
- To: "'Jon Hanna'" <jon@hackcraft.net>, w3c-wai-ig@w3.org
Jon Hanna wrote: There is no need to use the <a> element when you are using id, you can put the id onto any element in the content. If maintaining backwards compatibility I'd personally prefer to use id on an element surrounding the section in question, even if name was still used. <p id="intro"> <a name="intro"></a>introductory paragraph. </p> An attribute of type ID is supposed to be unique to the document. I realize that "name" and "id" are different attributes, but realistically ... the real reason this seems to work is just that most browsers don't actually enforce uniqueness. <p id="intro" name="intro">text</p> would be better, except that old browsers probably won't see the name on anything but <a></a>. Perhaps it would make sense to use a convention, such as prepending "start" to the id when creating the otherwise useless target anchor. <p id="intro"><a name="startintro"></a> text</p> Then #startintro would be used when you want a point target (as with navigation), but #intro would be used for actions (like CSS) that apply to the entire section. -jJ
Received on Thursday, 22 January 2004 09:38:45 UTC