change placeholder image to big on main product
-
I do have this code below in my functions.php
Yes it does change the placeholder to the selected image in categories but in main product page, the image is to big.I have the main image in wc settings: 300x300px
i upload 600×600, because of retina devices.Now is there something else to put in the code to get this fixed?
https://docs.woothemes.com/document/change-the-placeholder-image/
/* * goes in theme functions.php or a custom plugin. Replace the image filename/path with your own :) * **/ add_action( 'init', 'custom_fix_thumbnail' ); function custom_fix_thumbnail() { add_filter('woocommerce_placeholder_img_src', 'custom_woocommerce_placeholder_img_src'); function custom_woocommerce_placeholder_img_src( $src ) { $upload_dir = wp_upload_dir(); $uploads = untrailingslashit( $upload_dir['baseurl'] ); $src = $uploads . '/2012/07/thumb1.jpg'; return $src; } }
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘change placeholder image to big on main product’ is closed to new replies.