Forum

Thread tagged as: Problem, Configuration, Hosting

Image resizing issue

My client has recently migrated their Perch site to Amazon hosting, and we've since been having an issue with image assets - specifically the auto thumbnail resizing.

When attempting to add image assets via admin (either via the asset manager, or via the in-page editor) the resized versions fail to show.

I can see via SFTP that the source image itself is uploading ok, so no issues with permissions (perch > resources = 777).

We have Imagemagick installed & it doesn't seem to be presenting any obvious issues. I've screen grabbed the plugin info here: https://www.rockymountainpizza.com/imagick.png

Any help appreciated.

Tim

Diagnonstics:

Perch: 3.0.10, PHP: 7.0.21, MySQL: mysqlnd 5.0.12-dev - 20150407 - $Id: b5c5906d452ec590732a93b051f3827e02749b83 $, with PDO
Server OS: Linux, apache2handler
Installed apps: content (3.0.10), assets (3.0.10), categories (3.0.10), perch_blog (5.6.1), perch_shop_orders (1.2.5), perch_shop_products (1.2.5), perch_shop (1.2.5), perch_members (1.6.2)
App runtimes: <?php $apps_list = [ 'perch_blog', 'perch_members', 'perch_shop', ];
PERCH_LOGINPATH: /perch
PERCH_PATH: /var/www/html/perch
PERCH_CORE: /var/www/html/perch/core
PERCH_RESFILEPATH: /var/www/html/perch/resources
Image manipulation: Imagick
PHP limits: Max upload 20M, Max POST 20M, Memory: 128M, Total max file upload: 20M
F1: 3b606135b33e6a102526838f4152a807
Resource folder writeable: Yes
HTTP_HOST: www.rockymountainpizza.com
DOCUMENT_ROOT: /var/www/html
REQUEST_URI: /perch/core/settings/diagnostics/
SCRIPT_NAME: /perch/core/settings/diagnostics/index.php
Tim Denton

Tim Denton 0 points

  • 3 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

So you're getting the master image but no resizing?

I've done some further testing & this is what's happening:

  • The full-size original image uploads ok, and actually displays on the front end
  • No resized versions of the image are created within the resources folder. Only the original file is present.
  • Therefore, no thumbnail versions are available in admin.

T

Drew McLellan

Drew McLellan 2638 points
Perch Support

Is resizing working in your dev environment?

Yes it is. After doing some further research - I modified the perch > core > lib > PerchImage.class.php > PERCH_IMAGE_LIB to use imagick & not GD.

All working ok now.

Duncan Revell

Duncan Revell 78 points
Registered Developer

Don’t edit core files - change it in the config file instead.

https://docs.grabaperch.com/perch/configuration/images/

Rachel Andrew

Rachel Andrew 394 points
Perch Support

Thanks Duncan

Tim: please ensure that your files are as shipped by Perch, we can't offer support once you are editing core files,