How to not enlarge the image

See all posts See thread Reply

Re: How to not enlarge the image new!
by colin, 9 years ago
You cannot use two image_ratio_xxxx properties at the same time. In fact, you cannot have a "no_zoom_out" effect if you are using image_ratio_y, it is a known shortcoming.Reply
Re: How to not enlarge the image new!
by Chan, 9 years ago
Any solution to accomplish my goal?Reply
Re: How to not enlarge the image new!
by colin, 9 years ago
I am afraid you will have to do it outside the class, using image_src_x and image_src_y to check whether you need to resize or not.Reply
Re: How to not enlarge the image new!
by Chan, 9 years ago
It's works for me, thanks
$foo->file_new_name_body = $newName;
$foo->image_convert = 'jpg';
$foo->jpeg_quality = 100;
if ($foo->image_src_x > $maxWidth) {
  $foo->image_x = $maxWidth;
  $foo->image_resize = true;
  $foo->image_ratio_y = true;
}
Reply