WordPress.org

Ready to get started?Download WordPress

Forums

Overlay "Zoom" icon over wp-caption images? (3 posts)

  1. mhains
    Member
    Posted 5 years ago #

    Can anyone offer the necessary CSS coding to overlay a transparent GIF file over the thumbnail images used in the caption?

    hope you can help,
    Michael

  2. mhains
    Member
    Posted 5 years ago #

    Bump!

  3. soukie
    Member
    Posted 4 years ago #

    Yes, it's doable:

    div.wp-caption {
    position: relative;
    display: block;
    }
    .wp-caption a[href$=".jpg"]:before {
    content: url(magnify.png);
    position: absolute;
    right: 20px;
    top: 20px;
    }

    See http://soukie.net/2009/08/20/typography-and-css/#example for more details and example. I am actually using :hover:before. Plus you might need to extend the list of file types but that's simple.

Topic Closed

This topic has been closed to new replies.

About this Topic