- From: Tantek Celik <tantek@cs.stanford.edu>
- Date: Thu, 25 Jul 2002 14:47:29 -0700
- To: Boris Zbarsky <bzbarsky@MIT.EDU>, Jerry Baker <jerrybaker@attbi.com>
- CC: Stuart Ballard <sballard@netreach.com>, www-style <www-style@w3.org>
On 7/25/02 2:28 PM, "Boris Zbarsky" <bzbarsky@MIT.EDU> wrote: > >> Although I might be ignorant of some other purpose of which I haven't >> thought, why can't named anchors be specifically excluded from :hover >> and :active? > > Because CSS is markup-language-independent and thus has no concept of a > "named anchor". All it knows is that there is a <a> element. Any other > semantics are attached to the <a> by the document language, which > happens to be HTML in this case. Precisely. Also, please note that named anchors are have been _removed_ from XHTML 1.1. http://www.w3.org/TR/xhtml11/changes.html#a_changes So, really what you _should_ do is stop using named anchors, and use the "id" attribute instead directly on the target element (i.e. don't use an unnecessary <a> element at all for the destination of a hyperlink), which is much better structurally than those empty named anchors that litter the web. > Keep in mind that CSS is not an adjunct to HTML but an adjunct to > XML-based markup languages in general. Exactly. Thanks Boris. Tantek
Received on Thursday, 25 July 2002 17:40:02 UTC