WordPress.org

Ready to get started?Download WordPress

Forums

Bottom border on image links - need to remove (3 posts)

  1. AndrewLilley
    Member
    Posted 7 years ago #

    Hi,

    I have created some nice dotted bottom-borders for my text links. However, the images also take this property. I've tried removing this by using:

    a img {
    bottom-border: none;
    }

    but this doesn't work. Why not?

    I've tried targeting text links only, without success. Targeting the body tag also affects images.

    How can I target the main text in the post, plus the navigation links, to have a bottom border, and not the images? This is driving me crazy as I would have thought the above code would work...

    Thanks!

  2. spencerp
    Member
    Posted 7 years ago #

    Your CSS code is backwards.. try this once:

    a img {
    border-bottom: none;
    }

    I hope this helps ..

    spencerp

  3. Doodlebee
    Member
    Posted 7 years ago #

    Also, if your anchor tags, by defulat are underlined, it's not a bottom border you're seeing. It's the anchor link text decoration you're seeing. You can try adding "text-decoration:none;" to the a img stuff in your CSS, but if that doesn't work, give the anchor a class name and give that class a no-decoration definition.

Topic Closed

This topic has been closed to new replies.

About this Topic