• Resolved Frans Blok

    (@frans-blok)


    On the front page of my blog, the featured image of the most recent post is shown in a square format. This means that part of the image is cropped away, since most of my images are rectangular landscape format.

    Is there a way to change this: make the front page image match it’s original aspect ratio?

Viewing 14 replies - 1 through 14 (of 14 total)
  • Hi Frans. If this is your site then the reason it’s a square is because the image being used is a 720×720 square. The theme CSS sets the image to 100% width. The height is set to “auto” so it’s adjusted proportionately which ends up being the same as the width.

    Thread Starter Frans Blok

    (@frans-blok)

    Thanks for the reply. That’s indeed my site. But the original image is not a square but a 1600 x 1062 rectangle.

    the image being used is a 720×720 square

    That’s the image that’s in your media library.

    Thread Starter Frans Blok

    (@frans-blok)

    Does that mean WordPress makes a copy for a featured image and crops it to 720×720? Because the same images is also in the blogpost without crop as a 1600 x 1062.

    I don’t know a lot about WP image handling and personally it’s one of my least favorite parts of WP. Personally I think the whole medial library functionality needs an overhaul but that’s just my opinion, and that doesn’t help solve your issue. What I do know is that the theme Featured Posts option uses the “thumb-large” thumbnail of the featured image assigned to the post. That thumbnail default is 720×340 and is created by the theme when an image is uploaded to the Media Library. The “thumb-large” image size in your post appears to have been changed to be 720×720. That could have been done by modifying the theme function that creates the thumbnail images, or by adding new images sizes and regenerating thumbnails, or modifying it outside the the library, or another plugin; hard to tell without actually looking at your configuration.

    When you embed an image within the post content you can select the image size from the sizes created by WP. If you select “Full Size” then the original image will be used. In the case of your image that’s 1600×1060 which is a ratio of 1.509-to-1. That image is then resized dynamically with CSS to 100% of the content width. On your site that’s 1000px less 30px of right/left padding = 940px. The image height is set to “auto” so it contracts proportionately to 623px (940 / 1.509 = 623).

    Thread Starter Frans Blok

    (@frans-blok)

    Thanks for the clear explanation. After reading it I thought the issue might be solved by changing the media-settings (sizes of large image/adjust thumbnail to sizes), but that doesn’t have any effect. In the theme options I can’t find anything about media sizes. So I’m afraid I’ll have to dive deeper into the matter and modify the css.

    Anonymous User 12851872

    (@anonymized-12851872)

    Hi,
    sorry but in the demo http://demo-hueman.presscustomizr.com/
    The post-thumbnails aren’t square.
    The size is 520×245 pixels.

    then the use of width and height attributes in the img tags to reduce the display size of an image is not a recommended alternative, from what I read.

    Thank you

    Thread Starter Frans Blok

    (@frans-blok)

    That’s odd… So in this theme the thumbnails’ default is a 2:1 ratio? I like that a lot better… So how did they become square?

    Thread Starter Frans Blok

    (@frans-blok)

    Allright, I found the solution. I had to run the regenerate thumbnails plugin after changing the thumbnail size.

    Anonymous User 12851872

    (@anonymized-12851872)

    Hi,
    you must have the latest version of Humean, you have the version 1.3.4.
    a site must be 100% updated, all the time, you must have the latest version of WordPress, the latest version of all the themes, the latest versions of all plugins

    WordPress 4.5.3
    https://wordpress.org/

    Hueman 3.1.6
    https://wordpress.org/themes/hueman/

    After changing the size of images, always use the plugin regenerate thumbnail.

    Remember to empty your memory cache after plugin.
    For my part, I prefer the WP Fastest Cache plugin, which I find better than WP Super Cache.

    Thread Starter Frans Blok

    (@frans-blok)

    After having had some serious trouble after updating to the latest versions, up to complete disappearance of my site, I’ve become a bit hesitant. But I promise to better my life.

    Anonymous User 12851872

    (@anonymized-12851872)

    There must be a problem with your site configuration, you must be under PHP5.5, better PHP5.6
    you have installed WordPress you, especially not even taken an option from your webhost?
    name of your hoster, is it you please?
    A website not updated risk more attacks by hackers
    Before upgrading, make a backup of your database, disable all plugins and then update WP.
    Thank You

    Thread Starter Frans Blok

    (@frans-blok)

    All those times, the problems have been eventually resolved. All I’m saying is: once you’ve spend two frustrating days before your blog is back online, you’re not too eager to immediately do every update. Even though it may be wiser to do so.

    Anonymous User 12851872

    (@anonymized-12851872)

    I understand, I’ve been there, and precisely for fear of hacker my site, I always kept up to date, I am more cautious now, twice, I got hacked my site.
    I will not insist, but the name of your host?

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘Front page image size’ is closed to new replies.