Here’s a tiny snippet based a question from Julie:

How can I add a notice right below the WooCommerce featured image on the product page? It should say “click to enlarge” right below the image.


There’s an action that you can use to add content below featured images, which can be used before or after product thumbnails. The woocommerce_product_thumbnail action is what will help us out. Let’s add a notice that says, “Click to Enlarge” below the featured image.

We’ll use a function to insert this text as a heading below the featured image. You can add this to your child theme or, even better, a code snippet using the Code Snippet plugin.

We’ll now have this displayed right below our featured image.

WooCommerce Product Images

Standard images

WooCommerce image notice

Images with Notice

We could also put this notice below the product thumbnails instead if desired. Use the same snippet, but change the priority from ‘9’ to ’20’ like this:

add_action( 'woocommerce_product_thumbnails' , 'skyverge_add_below_featured_image', 20 );

We’ll end up with a notice after our thumbnails instead:

WooCommerce image notice 2

Unfortunately, some themes override WooCommerce templates and remove this action, so if it doesn’t work, your theme is probably one of these. Otherwise, you can add whatever content is needed to your images!

Published by Beka Rice

Beka leads product direction for SkyVerge and technical documentation. She spends a lot of time on research and interviews, but likes to write so she has an excuse to spend more time jamming out to anything from The Clash to Lady Gaga.

6 Comments

  1. Hi Beka,

    Thanks for that snippet, genius 🙂
    I’d like to add that feature to certain products, is it possible???

    Many thanks!

    Nor

  2. Thanks & had copied to code snippets.

    • Hi Beka,

      Thanks for that again 🙂 I was thinking there was a way of conditioning and arraying 🙂 giving it a go now…

      Thanks a lot again…

      Cheers

      Nor

  3. Please tell me how can I add new text box under product image on single page like this site have. http://postimg.org/image/6uzknukbl/

    also I add 200×200 px images on product page but size of images on single product page are very large how can I fix it too.

    Regards

  4. is there a plugin for this?

    I feel that there should.

Comments are closed.