Announcement

#1 2022-03-06 05:33:25

klinsinow
Member
2019-01-20
4

Piwigo PHP 8.0 compatibility?

Recently Bluehost upgraded it's PHP servers and broke some Piwigo functionality. Website works after reverting back to PHP 7.3 on Host. Below were the issues with PHP 8.0.


Piwigo 12.2.0 (was 11.5 when stopped working, I upgraded thinking that would help, which didn't)
Operating system: Linux
PHP: 8.0.16
MySQL: 5.7.23-23
Graphics Library: ImageMagick 6.9.10-68
Cache size 6869.07 Mo

Issues
1. Upload from Lightroom using Piwigo Export Plug-In vs3.1.0 no longer able to login and has error text: Error processing server response. trailing garbage at byte 28 of: {"stat":"ok","result":true}Deprecated: Directive 'allow_url_include' is deprecated in Unknown on line 0.

2. Not able to add images manually through website. Basically the album selection pulldown menus do not work (nothing shown in the list).

3. Keywords on left of main screen all have code instead of just text (i.e. /home1/jeffspho/public_html/_data/templates_c/ljbwkp^bfa63e235ebb16536a9d707f50be0b318694aa3d_0.file.menubar_tags.tpl.php on line 37
" href="index/tags/7-backpacking" title="display photos linked to this keyword">backpacking

4. If I go to PHP 8.1 on host, has (Deprecated: strip_tags(): Passing null to parameter #1 ($string) of type string is deprecated in /home1/jeffspho/public_html/include/functions_html.inc.php on line 534) across top of website about 10 times as well as still issue with keywords listing code instead of just the keyword.

5. Huge list of plugins (actually almost all) were non-functional with PHP 8.0


Are other people having issues with Piwigo and PHP 8.0 or 8.1?

I performed upgrade to Piwigo 12.2.0, however should I instead do a fresh install? If recommended, is there an export and import for the image database that I would use?

Thanks for anyone's insight on the issues!

Again, website working for me now with PHP 7.3, however by reading forums I thought Piwigo would support PHP 8.0. And eventually, bluehost may decide to drop PHP7.3 which would cause website to not function.

Offline

 

#2 2022-03-06 10:31:02

Katryne
Member
2016-12-03
369

Re: Piwigo PHP 8.0 compatibility?

Hello ! I installed a new Piwigo 12.2.0 2 weeks ago. Most plugins did not work, some giving blank pages, when I discovered that Ionos installed php8 by default for new domains/sub-domains. Without any plugin, Piwigo seemed to run correctly with php8. I did not test further and came back to php 7.4 to install my usual plugins. I will wait untill they are mended before testing again php8.
Plugins are the problem with php8, I think and most of them do not depend on the Piwigo  team.


http://photos.katrynou.fr/ v.14.1.0 https://album.chauvigne.info/ v.13.8.0
Système d'exploitation: Linux - Hébergeur 1&1-Ionos PHP: 8.0.28 - MySQL: 5.7.38
Bibliothèque graphique: External ImageMagick 6.9.10-23

Offline

 

#3 2022-03-13 11:35:28

matthys
Member
2014-04-02
188

Re: Piwigo PHP 8.0 compatibility?

I just did a test upgrading to PHP: 8.0.8 and I guess there are still some problems :-(

Plugins (I used) causing problem where:
Social Buttons

Warning: Attempt to read property "value" on null in /var/www/localhost/_data/templates_c/110vykv^ccbd11aef2aaecc80e874858eca7b26308c48c7c_0.file.facebook.tpl.php on line 28

After disabling it it was gone .... but still:

I also got these from the menu bar under Tags and Menu:
/var/www/localhost/_data/templates_c/110vykv^8fada83f5f47f8632a8aae9a195a9f9925a84f5e_0.file.menubar_tags.tpl.php on line 37
/var/www/localhost/_data/templates_c/110vykv^182776a969c923e5aa1bcac60e5485111be38b0a_0.file.menubar_menu.tpl.php on line 45


    Piwigo 12.2.0 Check for upgrade
    Operating system: Linux
    PHP: 8.0.8 (Show info) [2022-03-13 11:21:08]
    MySQL: 8.0.28-0ubuntu0.21.10.3 [2022-03-13 11:21:08]
    Graphics Library: External ImageMagick 6.9.11-60
    Cache size N/A   never calculated Refresh

<strike>Gone do a rollback to PHP7.4</strike> = have not done this for the moment

Last edited by matthys (2022-03-14 11:36:24)

Offline

 

#4 2022-03-13 12:15:10

matthys
Member
2014-04-02
188

Re: Piwigo PHP 8.0 compatibility?

These menu errors/warnings are related to BlancMont XL theme, which I guess is also not supported any longer :-(

Thought it also could be related to the Smarty plugin used by Piwigo.

PS ... suppress error and warnings did the trick but doesn't mean it's fixed :-(
Added to Local config:

Code:

$conf['show_php_errors'] = E_ALL & ~E_DEPRECATED & ~E_NOTICE & ~E_WARNING;

Last edited by matthys (2022-03-13 13:05:13)

Offline

 

#5 2023-09-14 22:50:13

Martin-V
Member
2017-02-14
6

Re: Piwigo PHP 8.0 compatibility?

Hello,
today I made upg 11.0.0 to 13.8.0.
After that I also upgraded all plugins and themes.
I checked my pages/photos and I've got line on the top of screen:

Warning: Attempt to read property "value" on null in /xxxxx/xxxxxx/photos/_data/templates_c/1mjlwfa_rafr8z^6959fa2bff07fb8063f90af84ed865794173a70a_0.file.header.tpl.php on line 59

I tried this on php 8.1 and php 7.4 - the same.
DB is MariaDB  10.1.44-MariaDB (server is on webhosting)

How to fix that?
Do I need to set
$conf['show_php_errors'] = E_ALL & ~E_DEPRECATED & ~E_NOTICE & ~E_WARNING;
?

Thanks,
Martin

Offline

 

#6 2023-09-15 23:00:03

erAck
Only trying to help
2015-09-06
2026

Re: Piwigo PHP 8.0 compatibility?

Either disable displaying deprecated and warning messages (because it effectively may break functionality of a page even if nothing else is broken), in local config

$conf['show_php_errors_on_frontend'] = false;

or fine tune message classes to display with $conf['show_php_errors'], or better, log to file instead.
See [Forum, post 180778 by erAck in topic 31258] Error Message.


Running Piwigo at https://erack.net/gallery/

Offline

 

#7 2023-09-16 17:07:25

Martin-V
Member
2017-02-14
6

Re: Piwigo PHP 8.0 compatibility?

Hi erAck,
thank  you for reply.

I tried my web again and warning reported above disappeared (no change done).

But when opened a single photo I have got:

--
Notice: Trying to access array offset on value of type null in /xxxxx/xxxxxx/photos/plugins/meta/main.inc.php on line 200

Notice: Trying to access array offset on value of type null in /xxxxx/xxxxxx/photos/plugins/meta/main.inc.php on line 204

Warning: Cannot modify header information - headers already sent by (output started at /xxxxx/xxxxxx/photos/plugins/meta/main.inc.php:200) in /xxxxx/xxxxxx/photos/include/page_header.php on line 99
--

I have checked plugin meta and its configuration. I found no meta defined so I disabled the meta plugin.
Then also this warning disappeared.

Now no warning msg.  ;-)

I also changed to php 8.1 - and still ok.

Thx and have a nice day,
Martin

Offline

 

#8 2023-09-17 06:14:10

ddtddt
Piwigo Team
Quetigny - France
2007-07-27
7207

Re: Piwigo PHP 8.0 compatibility?

Hi :-)

@Martin-V

can you test replace file by

http://piwigo.org/svn/extensions/meta/main.inc.php


You love Piwigo so don't hesitate to participate, learn more on the "Contribute to Piwigo" page. If you don't have much time for contribution, you can also help the project with a donation.

Offline

 

#9 2023-09-18 01:41:53

k5
Member
2017-11-05
68

Re: Piwigo PHP 8.0 compatibility?

Hi :)
@ddtddt
i am testing your code and It works if there is a description but if there is no description it gives an error

Thanks
k5

Offline

 

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2024 · Contact