Unable to change the image size in the catalog #1174
Replies: 2 comments 3 replies
|
Hello, converted this issue into a discussion, because this is no issue.
Impossible to check what you mean without having a link to your site to inspect and debug. We will always ask for a link as described in the guidelines. If you are on your local computer, transfer a copy to a live server first and share the url to reproduce and understand your issue, thank you!
Bootscore has no Customizer functions and WooCommerce loop is overridden in the theme. No Customizer setting will have any impact on your site, use code.
The Bootstrap .card-img, .card-img-top, .card-img-bottom {
width: 100%;
}You can change the WooCommerce loop images class with simple filters in your child-theme's /**
* Change product loop image class
*/
add_filter('bootscore/class/woocommerce/product/loop/img', 'change_product_image_class');
function change_product_image_class($classes) {
return 'my-custom-class';
}
/**
* Change category loop image class
*/
add_filter('bootscore/class/woocommerce/category/loop/img', 'change_category_image_class');
function change_category_image_class($classes) {
return 'my-custom-class';
}Just replace Solved? |
|
@crftwrk said:
I thought wordpress used the thumbnail width setting while it's cropping the images after you upload them from the media page. Is there another place where this value is stored? |
Uh oh!
There was an error while loading. Please reload this page.
The images in the catalog, in my installation, are hugh when shown in a computer or tablet screen (not in a phone, they render well).
If I try to use the Customizer > Woocommerce > Product Images to change the thumbnail width (300 px) I don't get any result.
The problem seems to be related to the class 'card-img-top', used in the image tag despite being inside a list, not in a card. If I disable, using the browser inspector, the class I can see the image correctly.
I'm using Bootscore last version.
Thanks in advance.
All reactions