We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

Change ED ImageResizer Crop method

Development and Programming

chealey's avatar
chealey
95 posts
15 years ago
chealey's avatar chealey

Hello,

I’ve been having some trouble trying to figure out how to get the Ed_ImageResizer to crop differently. I would like it to crop from the bottom rather than from the center. The top portion of the img files i’m trying to display are the most important, the middle is actually least important, so it cropping from the middle is not ideal at all for me.

Could anybody help me with a resolution to this problem?

I am using the 0.90 version on ee2.0 Thanks a lot in advance!

       
chealey's avatar
chealey
95 posts
15 years ago
chealey's avatar chealey

Got a solution on line242 you just change

$this->offsetY      = ($this->origHeight - $this->height) / 2;

to this

$this->offsetY          = 0;

…if anybody else has the desire to crop from the bottom rather than the center like i did.

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.