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
// Add the div to wrap the image on the archive pages | |
add_action( 'woocommerce_before_shop_loop_item_title', create_function('', 'echo "<div class=\"archive-img-wrap\">";'), 5, 2); | |
add_action( 'woocommerce_before_shop_loop_item_title',create_function('', 'echo "</div>";'), 12, 2); | |
// If there is sub categories on the archive page add a wrap around their images as well | |
add_action( 'woocommerce_before_subcategory_title', create_function( '', 'echo "<div class=\"sub-archive-img-wrapper\">";'), 5, 2 ); | |
add_action( 'woocommerce_before_subcategory_title', create_function( '', 'echo "</div>";' ), 12, 2 ); |