Closed Bug 168775 Opened 23 years ago Closed 23 years ago

a:hover works on anchors, too

Categories

(SeaMonkey :: General, defect)

x86
Windows 2000
defect
Not set
normal

Tracking

(Not tracked)

VERIFIED INVALID

People

(Reporter: profi-1, Assigned: asa)

Details

while designing a webpage I noticed that, with Mozilla, the pseudoclass ":hover" is assigned to anchors. Therefore, my headline becomes small and underlined while hovering over it. :)
IMHO INVALID, because if you have in style definition line like this: A:hover {font-size:12px;text-decoration:underline} Mozilla is just doing what you want. Maybe construction like this should help you: <H2><A NAME="fooname"></A>My Headline</H2>
":hover" is, and should be assigned to any <a> tag, regardless of what properties they contain. Reporter, change your site as Adam suggests. Marking this bug as INVALID.
Status: UNCONFIRMED → RESOLVED
Closed: 23 years ago
Resolution: --- → INVALID
Just adding my .02 euro. Use :link {...} :link:hover {...} :link:active {...} :link:active:hover {...} :visited {...} :visited:hover {...} :visited:active {...} :vistied:active:hover {...} and leave the <a> element alone. Or use the above statements with the "a" prepended for clarity (i.e., a:link:hover). The point is that you should only define style for links, not for anchors per se. Occasionally, you might want to define a style for anchors that are not links, because they are usually invisble. This presents a problem for developers used to only consider the <a> element, but I think there are few FAQs around on the matter.
Status: RESOLVED → VERIFIED
Related: bug 127468, :hover applies to non-link elements. (Also invalid)
Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.