[Resolved] Featured Images: Crop to fixed height?

Home Forums Support [Resolved] Featured Images: Crop to fixed height?

Home Forums Support Featured Images: Crop to fixed height?

Viewing 15 posts - 1 through 15 (of 16 total)
  • Author
    Posts
  • #174186
    Paul

    Hey Tom.

    I have the latest theme and addons plugin, but I am struggling to have the featured image on my posts “cropped” to a fixed height with auto width.

    i.e. I have an image that’s 1600×1200, but I want to “crop” all featured images to 1200 x 300 (middle aligned)

    I assumed I could set the featured image, and then use the header image settings to fix either the height (400px) and set the “hard crop”.

    But any combination of these values does not give the desired result.

    What am I doing wrong, Tom?

    #174190
    Tony

    I think (not 100% sure) this is something I have worked on with Tom.

    If you put one of the measurements into the ‘Image Height’and 9999 or 0 into Image Width and enable hard crop it will size it and the the width will be proportional to the height.

    It fails if you put a measurement in width and 0 in height.

    I’m sure Tom knows about this.

    #174195
    Paul

    Thanks Tony.

    I’ve tried various combinations of 0, auto and 9999, and nothing has the desired effect. It’s either the case that I am not quite getting the combinations right, or it is not possible to do what I am wanting to.

    #174196
    Paul

    For example, I just tried:

    Hard Crop
    
    Image Width: 1200px
    
    Image Height: 300px

    … and all that happens is the image height is 300px and the width sized proportionately to 400px. i.e. the image is not “cropped” to 300px height (middle align vertical) at 1200px wide.

    #174197
    Tony

    Ah – I see, you are not wanting to crop it proportionally so it won’t do what you want using my method.

    Over to Tom.

    #174207
    Tom
    Lead Developer
    Lead Developer

    In order to use the sizing options in the Page Header metabox you need to upload your image through it as well – the sizing won’t work if you uploaded the image through the “Featured Image” metabox.

    Let me know if that works or not πŸ™‚

    #174388
    Paul

    Hey Tom.

    I am on 1.2.79 of the GP Premium add-on.

    I removed the featured image and added it through the Page Header metabox.

    I set the hard crop to “enabled”.

    I set the height to 300px.

    I set width to 1200px, 9999px etc.

    Bottom line, when I set the height to 300px, the width is always proportionately fixed to 400px.

    E.g. http://visceralshift.com/index.php/2016/01/18/so-much-going-on-right-now/

    #174454
    Tom
    Lead Developer
    Lead Developer

    Can you shoot me an email to support@generatepress.com so I can send you the latest beta version?

    #174457
    Paul

    I can Tom.

    Am I at least expecting the right outcome with what I was trying? πŸ™‚

    #174461
    Tom
    Lead Developer
    Lead Developer

    Yea that should work perfectly (just did it myself) πŸ™‚

    #174462
    Paul

    So what am I doing wrong?? Should be a clean install on that domain… am I missing something?

    #174464
    Tom
    Lead Developer
    Lead Developer

    I made some changes to the cropping in this beta version so lets see if it’s that first.

    If not, I’m going to guess there’s a plugin interfering.

    #174466
    Paul

    Ok, my friend. Will try this later today!

    #175056
    Tom
    Lead Developer
    Lead Developer

    Hi Paul,

    This was the Photon module in the Jetpack plugin.

    I deactivated it and it’s all working as it should now.

    #175159
    Paul

    Well I’ll be damned; the joys of multi-function plugins.

    Thanks for the help, Tom … appreciate it!

Viewing 15 posts - 1 through 15 (of 16 total)
  • You must be logged in to reply to this topic.