Skip Navigation

[Résolu] custom sized thumbnzil images don't appear

This support ticket is created Il y a 5 années et 4 mois. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

Marqué : 

This topic contains 5 réponses, has 2 voix.

Last updated by Christian Cox Il y a 5 années et 3 mois.

Assisted by: Christian Cox.

Auteur
Publications
#1173464

I created a view with custom sized images. All is well on my staging server, but when I install the same archive locally the images disappear. Dafault image size still works though.
Any ideas?

#1173526

Hi, it's hard for me to say but there are a few possibilities:
- Your staging server was HTTPS and your local test environment is HTTP, but the migration script you used to migrate the site didn't change all the URLs correctly. Now a mixed-content error is preventing load HTTPS images over HTTP.
- Your migration script didn't copy all the images correctly from the staging server into your local environment.
- There is a localhost configuration issue preventing WordPress's image processing system from creating resized images.

Open the browser console and check for any error messages. Copy + paste those here for me to review. Tell me more about how you migrated from the staging site to your local environment. Did you run a custom database script? Did you use a 3rd-party migration tool like Duplicator or All-in-One WP Migration?

#1174262
Schermafdruk 2018-12-28 15.23.29.png

First I created an archive through cPanel.
Then I used DesktopServer with SSL locally enabled to import the archive. Apart from this specific problem the site runs well.
This the error message I get in the console: see attachment

#1174827

First I created an archive through cPanel. Then I used DesktopServer with SSL locally enabled to import the archive.
Okay I'm not familiar with DesktopServer's import process so I don't have any specific advice there. I don't see any 404 errors about missing images in the screenshot you provided. One missing development javascript file, but nothing to be concerned about. When you inspect the page source, are the image tags included in the page content at all? If so, and no 404 errors are shown in the console related to these images, then there is most likely a problem with CSS or JavaScript.

Are you able to turn on server logs on your local environment? If you're not familiar with logs, I can show you how to turn them on temporarily. Go in your wp-config.php file and look for

define('WP_DEBUG', false);

Change it to:

define('WP_DEBUG', true);

Then add these lines, just before it says 'stop editing here':

ini_set('log_errors',TRUE);
ini_set('error_reporting', E_ALL);
ini_set('error_log', dirname(__FILE__) . '/error_log.txt');

Then reload the page where images are missing. If any backend errors are generated, this will create an error_log.txt file in your site's root directory. Please send me its contents. Once that is done, you can revert the changes you made to wp-config.php.

#1180715

I edited wp-config but for some reason the error log file is not generated.
Image tags are not included in the code.

This is the piece of code:

<div class="main-list">
<a href="[wpv-post-url]">[wpv-post-featured-image size="custom" width="65" height="65" class="alignleft" crop="true"]</a><h4>[wpv-post-link]</h4>
</div>

When I change this to

<div class="main-list">
<a href="[wpv-post-url]">[wpv-post-featured-image]</a><h4>[wpv-post-link]</h4>
</div>

the images appear as expected.

Strange.

#1180899

Try adding some invalid PHP in your theme's functions.php file to generate a fatal error, then check to see if an error_log.txt file is generated. If so, then you know the wp-config.php settings are correct but there are simply no errors generated by the shortcode. If no log file is generated, then there's a problem with logging, you'll need to investigate that on your local environment. It may be that your localhost or MAMP is automatically logging somewhere else, or has disabled all logging, etc.

Try a different built-in size, like size="thumbnail", and remove the height and width attributes. Is the standard thumbnail-sized image shown? If not, there could be a problem with the image manipulation PHP extensions on your server, or the resized image directory cannot be written to for some reason like file permissions.

I suppose it could also be a memory issue, you may want to confirm you've got at least 128M and preferably 256M available to WordPress. Normally that would generate a log message though.

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.