Home Forums WoodMart support forum Image crop / resize on product page

Image crop / resize on product page

Viewing 17 posts - 1 through 17 (of 17 total)
  • Author
    Posts
  • #472877

    mortengottliebsen
    Participant

    Hello

    I have managed to crop images on shop page, but when it opens up on product single page, the images are no longer cropped. Talked with woocommerce, and they suspect that your theme does not allow for the cropping on the single page product.

    Attachments:
    You must be logged in to view attached files.
    #472957

    Artem Temos
    Keymaster

    Hello,

    Could you please check how it works with some default WordPress themes like TwentyTwenty or WooCommerce Storefront to understand is it our theme issue or not?

    Regards

    #472977

    mortengottliebsen
    Participant

    Its 50/50, some looks right and some does still not look right.

    The first screen shot I sent you, there are the last 3 image sizes, they all end on “0”, they should end on the same as the first size, making a square. But I cant find where to change that.

    #472982

    Artem Temos
    Keymaster

    Sorry, but you didn’t attach a screenshot.

    #473119

    mortengottliebsen
    Participant

    here are the screen shots

    Attachments:
    You must be logged in to view attached files.
    #473213

    Artem Temos
    Keymaster

    Try to add the following PHP code snippet to the child theme functions.php file to do this

    add_filter( 'woocommerce_gallery_thumbnail_size', function ($sizes) {
    	return array( 150, 150 );
    });

    Also, leave this field empty in Theme Settings https://monosnap.com/file/PV0hXgKZE3FQ9jRgq2ktdEuLAvWHv8

    #473227

    mortengottliebsen
    Participant

    Been trying that. Only seems like the thumbnail is getting blury

    Attachments:
    You must be logged in to view attached files.
    #473268

    Artem Temos
    Keymaster

    Sorry, you need to enable thumbnails bottom position option in Theme Settings -> Single product -> Images. Then it will look similar to the default theme.

    Kind Regards

    #473269

    mortengottliebsen
    Participant

    there are no thumb nails now, after I changed. Screen flickers and they disapeer.
    But I still need to find a solution for the product image to be square.

    Attachments:
    You must be logged in to view attached files.
    #473272

    mortengottliebsen
    Participant

    actually the thumbnails are so far down I didn’t notise

    Attachments:
    You must be logged in to view attached files.
    #473327

    Artem Temos
    Keymaster

    In this case, you need to activate the autoheight option for the product gallery in Theme Settings.

    Kind Regards

    #473340

    mortengottliebsen
    Participant

    done that, but it still does not fix the issues with a square product image.

    #473353

    Artem Temos
    Keymaster

    Now it works as with the default theme. As per the WooCommerce configuration. What square images do you mean?

    #473379

    mortengottliebsen
    Participant

    The squares was my first question in this topic. Like the shop page, I want the product single page to be like this.

    Attachments:
    You must be logged in to view attached files.
    #473452

    Artem Temos
    Keymaster

    But as we understood from the first message, WooCommerce said that images should be cropped on the single product page too. But as you sent a screenshot from the default theme, WooCommerce doesn’t crop images on the single product page. So it is not a problem with the theme but the way WooCommerce works.

    #473457

    mortengottliebsen
    Participant

    My first screenshot shows the 3 last images, has a “0” as the hight. All the others are same size, so my question was where can I make those changes?

    Attachments:
    You must be logged in to view attached files.
    #473525

    Artem Temos
    Keymaster

    Hello,

    These image sizes are registered by the WooCommerce plugin, not by the theme. You need to refer to its documentation or support on this matter.

    Kind Regards

Viewing 17 posts - 1 through 17 (of 17 total)