Not showing thumbnails

Hello,

I have a fresh Elgg 1.8.19 install on my localhost (MacOS: Apache 2.2.26 + PHP 5.5.8) and on a remote server (Ubuntu: Apache 2.2 + PHP 5.5.0). Both machines have PHP GD extension enabled and correct data dir config (permissions and DB path) and same plugins configuration but on remote server I can't show thumbnail images in river activity, files list...

I've inspected HTML output on both machines and it seems that on remote server any image code is generated, it's not a 404 error becuase there is no IMG node rendered.

Thanks for your time. Best Regards.

  • Have you migrated the database of your local installation to the remote installation or have you started the remote installation with a fresh database? In the first case you would have to follow the instructions posted at http://docs.elgg.org/wiki/DuplicateInstallation and also copy the content of the data directory to the remote installation to see any existing images and their thumbnails. A different timezone set on your local server and the remote server could also result in the images not showing (http://docs.elgg.org/wiki/No_images).

    If you haven't started your remote installation by migrating the database from your local installation: can you upload any files at all, e.g. is a profile image displayed instead of the grey head and can you download any uploaded files (using the files plugin)? You can also check out if the files (image files and the corresponding thumbnails and any other files) are even saved in the data directory. First thing you should make sure is that the images are uploaded correctly and also the thumbnails are also created and saved (maybe they are not created due to memory issues - GD needs a lot of memory for larger images). If you know for sure that the image files are existing in the data directory (no 404 error might be misleading), I would start looking for possible reasons why the existing files are not displayed. In this case I would start checking for conflicts between due to 3rd party plugins (it might work on your local installation but still fail on the remote server).

  • Thanks @iionly

    Remote installation have a fresh installation. The images are uploaded inside data directory correctly. If I show my profile view I can't see my thumbnail, but if I go to editing avatar profile view the image is displayed. Finally GD is enabled and I have 64MB for PHP.

    The worst thing is that I don't have any 3rd party plugin installed :-(

  • On the "edit avatar" page the original uploaded image file is displayed, so the image being shown on this page is not a sure prove that the creation of the thumbnails has been successful. On the profile page (and elsewhere) the resized thumbnails of the avatar are used.

    Are you REALLY sure that the thumbnails are in the data directory and not only the original unresized image file? For example, there should be 6 image files with different sizes in the "profile" subfolder of your user's subfolder in the data directory. The file with "master" in the filename is the original uploaded image file while the others are created by GD.

    Also, if all 6 files are there, are the files of a file size larger than 0? It could be that the post_max_size setting is too small currently for all the image files to be handled correctly. If you don't have 3rd party plugin installed, I can only think that maybe post_max_size and/or memory_limit are set too small or the GD library is not working correctly for some reason. If you haven't already tried, I would suggest uploaded a very small image to see if this makes any difference (important is that the image resolution is small as the memory requirement for resizing is mostly depending on image resolution).

     

  • Solved!

    I don't know why, it seems that some files it won't be deployed:

    • mod/file/views/default/icon/object/file.php
    • views/default/icon/default.php
    • views/default/icon/user/default.php

    Fortunatelly, thanks to Git I found it.

    @iionly thanks for your help.