19th Feb 2007

How to get rid of tracing dotted line on a:active with CSS

How to get rid of tracing dotted line on a:active with CSS

You know those tracing dotted lines (see above) which appear when you click on a link? I found out not too long ago that you can get rid of them easily just by adding the following into your stylesheet file.


a {
outline: 0;
}

Technorati Tags: , , ,

Referral text link:

9 Responses to “How to get rid of tracing dotted line on a:active with CSS”

  1. steve Says:

    Only works in IE?

  2. eisabai Says:

    Hi steve,

    I don’t think it’s applicable for IE as you don’t see tracing dotted lines like that in IE. It’s mainly for FF.

  3. jab Says:

    Yes, it only works in IE. FF still has the tracing lines. I cannot get rid of them… and it is annoying.

    My style sheet looks like this:
    .a {
    font-family: Arial, Helvetica, sans-serif;
    font-size: 10px;
    color: #999999;
    text-decoration: none;
    outline: none
    }

  4. jab Says:

    any cures would be awesome

  5. eisabai Says:

    Hi jab,

    Try this:

    a {
    outline: none;
    }

    If that doesn’t work, try:

    a:focus {
    outline: none;
    }

  6. jab Says:

    the a:focus tag worked…PERFECTO!

    thanks!

  7. eisabai Says:

    You’re welcome.

  8. Bee Says:

    Any ideas on how to get rid of the same problem in FF on an input submit button?

  9. eisabai Says:

    Hi Bee,

    If you’re talking about the dotted line that you see when you click on an input button, I don’t think we can control that in CSS. However, you might be able to get around it by using an image instead of an input button.

Leave a Reply

Free Anonymous Proxy