php - Hook to overlap two image in product loop page and single page in woocommerce -
i working t-shirt designing plugin , going merge woocommerce plugin. in have overlap 2 image bellow.
white t-shirt ( set admin same product). t-shirt logo (uploaded designer product image when uploading product front end end , details goes woocommerce product section ).the t-shirt logo on top of white t-shirt.
is there hook overlap 2 image in product single page , product loop page in woocommerce.
there no specific hooks same.
store 2 images : 1 product image, other in post_meta product.
you can on lap 2 images on here : can utilize css overlap 2 images 1 did here : http://codepen.io/anon/pen/ijmtn
for changing image in product loop, need remove default woocommerce hook product thumbnail.
remove_action( 'woocommerce_before_shop_loop_item_title', 'woocommerce_template_loop_product_thumbnail', 10 );
and add together custom hook output required markup.
add_action( 'woocommerce_before_shop_loop_item_title', 'your_function', 10 ); function your_function(){ //your code }
for changing image single product page, there template in woocommerce single-product/product-image.php
. need override template out required markup
php wordpress woocommerce
No comments:
Post a Comment