Remove stubborn underline from link

dmr picture dmr · May 7, 2010 · Viewed 1.1M times · Source

I am attempting to have a link show up in white, without an underline. The text color shows up correctly as white, but the blue underline is stubbornly persisting. I tried text-decoration: none; and text-decoration: none !important; in the CSS to remove the link underline. Neither worked.

How can I remove the blue underline from the link?

Answer

Davor Lucic picture Davor Lucic · May 7, 2010

You are not applying text-decoration: none; to an anchor (.boxhead a) but to a span element (.boxhead).

Try this:

.boxhead a {
    color: #FFFFFF;
    text-decoration: none;
}