Page 1 of 1

Thumbnails from imgur are not displayed when filename starts with a letter

Posted: 29 Apr 2024, 14:29
by Spacecow84
Hi,

i have issues that the thumbnails from pictures imported from imgur are not displayed.
Pictures that are starting with a letter are not working, pictures starting with a number are working.
Since I can not change the name of imgur pictures I have no idea how to get it work.

This is how the gallery looks like:
https://imgur.com/Dob3FDm

If I edit the imgur imported images, the only difference is how the filename looks like:

Working:
https://imgur.com/w05JW9W

Not working:
https://imgur.com/S0AH6hv

If i click on the broken thumbnail, the picture opens normally.

I'm using 5.0.0 on Joomla 5.1.0 with php 8.1.28

Here is the gallery:
https://sgrn.sg-retzstadt.de/index.php/bilder

Thank you for your help

Re: Thumbnails from imgur are not displayed when filename starts with a letter

Posted: 03 May 2024, 01:55
by Jan
Hi, thank you for the info, will be fixed in next version.

The hot fix:

open: components/com_phocagallery/layouts/box_image.php

change line cca 38:

FROM:

Code: Select all

echo HTMLHelper::_( 'image', isset($item->extid) & (int)$item->extid> 0 ? $item->extm : $item->linkthumbnailpath, $item->oimgalt, array( 'class' => 'pg-image c-Image c-Image--shaded', 'itemprop' => "thumbnail"));
TO:

Code: Select all

echo HTMLHelper::_( 'image', isset($item->extid) & $item->extid !=  '' ? $item->extm : $item->linkthumbnailpath, $item->oimgalt, array( 'class' => 'pg-image c-Image c-Image--shaded', 'itemprop' => "thumbnail"));
Let me know if this works for you.

Than you, Jan

Re: Thumbnails from imgur are not displayed when filename starts with a letter

Posted: 04 May 2024, 09:11
by Spacecow84
Hi,

that hot fix works perfectly, thank you very much

Re: Thumbnails from imgur are not displayed when filename starts with a letter

Posted: 06 May 2024, 14:46
by Jan
OK