View Full Version : a:active in Foxfire not working

Oct 18th, 2008, 07:06 PM
I put my menu in a table with an ID, and each link is in a cell.
My css code is:
#nav a:active {
This works in Internet Explorer 7, but in Firefox, the background color of the cell does not remain white, while on the active page.
Can this be fixed?

Oct 18th, 2008, 11:43 PM
#nav a:active,#nav a:focus

it's just Firefox being all rebellious and independent ;)

Oct 19th, 2008, 04:39 PM
The :active pseudo class is not for “active pages” but rather for the active state of an element (an anchor in this case), i. e. the state while you hold your mouse button down when you click the element, and only for that long. One could say :active is the state the link is in as you click it.

Oct 19th, 2008, 11:24 PM
Yes, that's true, I was assuming qtone knew this. :active doesn't work in FF2 though, you need to add :focus.

Oct 20th, 2008, 01:04 AM
Thanks so much itsallkissa and VIPStephan - I never used focus for a link and couldn't understand why the active worked in IE but not FF. There's always something new to learn.