Remove Dotted Border on Hyperlinks with CSS

‘09 10th Nov
 by Adriaan

css-remove-dotted-border

I’m sure you’ve seen this happen on many websites – a dotted border appears on hyperlinks when you click on the link. This is specifically noticeable on images and also happens when clicking on an element inside an embedded flash object. You can see the visual representation in the header image of this post.

This is something that happens in Firefox and is easily fixable by adding a small piece of CSS to your hyperlinks and SHOULD BE cleaned up as it just polishes off you website as there’s nothing worse than looking at a really well designed website, but clicking on the buttons reveals a horrible dotted border that resembles something like a selection marquee in Photoshop.

Add the following in your stylesheet to eliminate the messy dotted border:

a:active { outline: none; } a:focus { -moz-outline-style: none; }

Now wasn’t that nice and easy and the small yet powerful impact is sure to polish out that ugly scratch on your site.

No Comments on “Remove Dotted Border on Hyperlinks with CSS” »

No comments yet.

Leave a comment


© Copyright 2009 thedesigner.co.za. Powered by Wordpress.