phpBB Gallery

PHP 8.1: Images "image_not_exist.jpg" & Co not showing - phpBB Gallery

PHP 8.1: Images "image_not_exist.jpg" & Co not showing

by Neverlands » Thu May 04, 2023 1:17 pm

Hello,
when I run the gallery with PHP 8.1 the images image_not_exist.jpg, no_hotlinking.jpg and not_authorised.jpg aren't displayed anymore. E.g. for "image not exitst": <img class="album-link" src="/gallery/image/0/mini" alt="" title="">
What needs to be changed to make them showing with PHP 8.1?

When I switch back to PHP 7.4 these images are shown (see screenshot in the attachment).
Attachments
not-exist.png
User avatar
Neverlands
Registered User
Posts: 118
Joined: Thu Sep 05, 2002 12:06 am
Location: Vienna / Austria

Re: PHP 8.1: Images "image_not_exist.jpg" & Co not showing

by Tarantino » Thu May 04, 2023 9:03 pm

Tarantino
Registered User
Posts: 876
Joined: Sat Feb 18, 2012 1:51 pm

Re: PHP 8.1: Images "image_not_exist.jpg" & Co not showing

by Neverlands » Thu May 04, 2023 11:53 pm

Thanks for the links, but I'm not sure if the posts relate to the same problem as mine.
I can see JPGs in my gallery. The only ones I don't see with PHP 8.1 are the images image_not_exist.jpg, no_hotlinking.jpg and not_authorised.jpg.
comparison.png
This is from my phpinfo():
phpinfo.png
User avatar
Neverlands
Registered User
Posts: 118
Joined: Thu Sep 05, 2002 12:06 am
Location: Vienna / Austria

Re: PHP 8.1: Images "image_not_exist.jpg" & Co not showing

by Tarantino » Fri May 05, 2023 12:14 am

Seem different. But in my case I was able to see jpg, and gif, but not all png's, only some pngs. All because of the profiles that most softwares adds, as photoshop. So dependening on how people saves the image, in some cases it creates a png with an invalid profile that its rejected by libpng.

In your case, those 3 images are the only ones not working? You need to check the network and see whats happening with those images.
Tarantino
Registered User
Posts: 876
Joined: Sat Feb 18, 2012 1:51 pm

Re: PHP 8.1: Images "image_not_exist.jpg" & Co not showing

by Neverlands » Fri May 05, 2023 12:42 pm

Yes, only these 3 images aren't working, all others work as they should.
The network tab simply doesn't show the image (in this case /gallery/image/0/mini), the other three album images are shown as file "mini", type "jpeg" or "png".
If I directly open the path https://mydomain/gallery/image/0/mini in my browser, I get this error displayed: "The image cannot be displayed because it contains errors".
If I directly open the path https://mydomain/files/phpbbgallery/core/mini/image_not_exist.jpg in my browser, the image is displayed correctly.

Has it maybe something to do with the creation of the path /gallery/image/0/mini, which PHP 8.1 can't work with?
Attachments
network.png
User avatar
Neverlands
Registered User
Posts: 118
Joined: Thu Sep 05, 2002 12:06 am
Location: Vienna / Austria

Re: PHP 8.1: Images "image_not_exist.jpg" & Co not showing

by Neverlands » Wed May 24, 2023 5:48 pm

I made another screenshot that shows, that the image is there, even with a file size, but is simply not displayed.
Any tip is appreciated.
Attachments
gallery-mini-0.png
User avatar
Neverlands
Registered User
Posts: 118
Joined: Thu Sep 05, 2002 12:06 am
Location: Vienna / Austria