tags:

views:

126

answers:

3

Just doing a little touch up before finishing a conversion project and I have an unwanted border-bottom that needs to be removed.

The base code is:

a:link, a:visited   { color: #000000; text-decoration: none; border-bottom: 1px dotted #c6132e; }

However, I don't want it to show up on all links, particularly the main navigation. When you click on any of the links there it shows up.

On line 56 of the css I placed this code to remove the border-bottom, but it doesn't seem to be working:

ul#main_nav li a:link,
ul#main_nav li a:visited
ul#main_nav li a:hover,
ul#main_nav li a:active     { border-bottom: none; }

Would appreciate a second set of eyes to look this over and help me find the solution.

Thanks!

BTW: here is the link: http://www.rouviere.com/aav/index.html just click on any of the main navigation buttons.

+4  A: 

You missed a comma. Should be:

ul#main_nav li a:link,
ul#main_nav li a:visited,
ul#main_nav li a:hover,
ul#main_nav li a:active     { border-bottom: none; }

Your rule is not applying to visited links.

iamtooamazing
Beat me to it. =D
Jeff Rupert
helpful but didn't solve the problem.
fmz
A: 

Have you tried using the !important decleration? It may be that your new styles are being overridden somewhere.

ul#main_nav li a:link,
ul#main_nav li a:visited,
ul#main_nav li a:hover,
ul#main_nav li a:active     { border-bottom: none !important; }

Also, as noted by @iamtooamazing, you missed a comma after the visited decleration.

Jamie Dixon
!important is not a substitute for proper precedence styling.
Tegeril
!important would not make any difference in this case as the selectors here are more specific than those in the first bit of CSS.
Jez
You're right, however it's a good way to quickly tell if your styles are being overridden somewhere else. Then you can go back and make the correct changes.
Jamie Dixon
!important should always be avoided. If you have to use it you either a) do not understand css or b) do not understand css.
corymathews
I tried changing it to border-bottom: 0px; and it still shows. Some very powerful code operating there.
fmz
@corymathews: I'm sure that's why the element was included in the CSS spec: to show newbs. No other possible use.
Adriano Varoli Piazza
@Jamie Dixon - unless of course your newest !important is being overridden by another, more specific !important...
Jez
A: 

As Timhessel said, it's your focus outline... although this isn't recommended you could add this to get rid of it:

ul#main_nav li a { outline-color: transparent; }
fudgey
Wow - how obscure. I have never seen an outline behave that way, but I am sure glad you figured it out. Thank you!
fmz