Here’s a quick tip on removing the links from product images in WooCommerce:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Remove image links from WooCommerce thumbnail images | |
* | |
*/ | |
add_filter('woocommerce_single_product_image_thumbnail_html','wc_remove_link_on_thumbnails' ); | |
function wc_remove_link_on_thumbnails( $html ) { | |
return strip_tags( $html,'<div><img>' ); | |
} |
We use this in conjunction with the removal of gallery images tip here. This makes our sign up page that much simpler. And nicer, dont-cha-think?