The Lodge is members-only design/dev videos and Office Hours.

Next Office Hours Session: "Implementing an SVG Icon System" Nov 30 - 6:00 PM Eastern

Image has a link border on it, I want it to none.

  • # April 24, 2008 at 5:27 pm

    I have an image and whenever I add a link to it, it then has a blue border around it. I don’t want it to have any border so…

    I have put the image in a div with an ID of "blue" and added this code to my style sheet:

    div#blue a {color:none; text-decoration:none}
    div#blue a:hover {color:none; text-decoration:none}

    Still I get a border, what am I doing incorrectly?


    # April 24, 2008 at 5:48 pm

    There might be a css rule for it but in your html page, when you put the anchor and image tag, do this….

    # April 24, 2008 at 5:58 pm

    thanks Nike, I appreciate it. I fixed it with

    a img { border:0; }

    Dang, that was easy!

    # April 24, 2008 at 6:11 pm

    This reply has been reported for inappropriate content.


    You can also add :-

    a {
    outline-style: none;

    This will hide the dotted border in firefox on the link when clicked.

    Tob :D

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

There's a whole bunch of content on CSS-Tricks.

Search for Stuff   •   Browse the Archives

Get the Newsletter ... or get the RSS feed