Hello,
With Piwigo 14.0 I get the following error that I didn't have in Piwigo 13.8:
PHP Warning: Undefined array key "SHOWMOGI" in /_data/templates_c/p6jhns^14fa551f995c229031db643b81ce50a63c8802ee_0.file.mog_adminphoto.tpl.php on line 121
PHP Warning: Attempt to read property "value" on null in /_data/templates_c/p6jhns^14fa551f995c229031db643b81ce50a63c8802ee_0.file.mog_adminphoto.tpl.php on line 121
Here is the content of line 121 in p6jhns^14fa551f995c229031db643b81ce50a63c8802ee_0.file.mog_adminphoto.tpl.php :
<?php if (($_smarty_tpl->tpl_vars['SHOWMOGI']->value == 1)) {?>
<span style="margin: 0 0 0 20px"><?php echo l10n('Metadata Open Graph link image');?>
Have a nice day,
OpenPicture
Environment
Piwigo 14.0.0 Check for upgrade
Installed on 26 November 2016, 7 years 3 weeks 2 days ago
Operating system: Linux
PHP: 8.1.26 (Show info) [2023-12-19 14:35:36]
MySQL: 8.0.35-cll-lve [2023-12-20 03:35:36]
Graphics Library: ImageMagick 6.9.12-93
Cache size 1733.47 Mo
Theme: Bootstrap Darkroom 2.5.18
Activated plugins (that give no PHP 8.1 errors)
Add < head > element
Additional Pages
Advanced Menu Manager
Change who added photo
Community
Crypto Captcha
Edit Filename
Embedded Videos
Extended Description
Grum Plugins Classes.3
GThumb+
Header Manager
Language Switch
LocalFiles Editor
Media Icon
Meta Open Graph
Most Commented
Permalink Generator
Perso Footer
Personal Favicon
Personal Plugin
Photo Update
Posted Date Changer
Rotate Image
RV Thumb Scroller
Smilies Support
Stop Spammers
Update Album
user delete photo
Deactivated plugins (that give PHP 8.1 errors)
Charlie's content 3.5
Check Uploads
PWG Stuffs
SmartAlbums
Thumbnail Tooltip
URL Uploader
User Tags
Whois online
Offline
Offline
Thanks erAck,
So I guess Metadata Open Graph 14.0.a also gives these errors. What's a bit curious is that I get the error even when all plugins are disabled.
Offline
Hi :-)
erAck wrote:
afer update with new plugin release ?
Offline
Hello ddtddt,
Yes, I have updated to Metadata Open Graph 14.0.a, but errors keep appearing with PHP 8.1 in my PHP error log file. I have already emptied the cache, purged compiled templates and trashed all files in templates_c folder.
The errors only stop when I go back to PHP 7.4 with Piwigo 14.0.
Offline
Hi :-)
in file initadmin.php line 92 have you
$template->assign('SHOWMOGI', "1");
}else{
$template->assign('SHOWMOGI', "0");
}
if no download file and replace
if yas can you replace 0 by a ?
Offline
Hi ddtddt,
Yes, in file initadmin.php line 92 I have :
$template->assign('SHOWMOGI', "1");
}else{
$template->assign('SHOWMOGI', "0");
}
and I changed it to :
$template->assign('SHOWMOGI', "1");
}else{
$template->assign('SHOWMOGI', "?");
}
But I still get the following error:
Undefined array key "SHOWMOGI" in /_data/templates_c/p6jhns^14fa551f995c229031db643b81ce50a63c8802ee_0.file.mog_adminphoto.tpl.php on line 121
[21-Dec-2023 14:38:46 UTC] PHP Warning: Attempt to read property "value" on null in /_data/templates_c/p6jhns^14fa551f995c229031db643b81ce50a63c8802ee_0.file.mog_adminphoto.tpl.php on line 121
[21-Dec-2023 14:38:47 UTC] PHP Warning: Undefined array key "SHOWMOGI" in /_data/templates_c/p6jhns^14fa551f995c229031db643b81ce50a63c8802ee_0.file.mog_adminphoto.tpl.php on line 121
[21-Dec-2023 14:38:47 UTC] PHP Warning: Attempt to read property "value" on null in /_data/templates_c/p6jhns^14fa551f995c229031db643b81ce50a63c8802ee_0.file.mog_adminphoto.tpl.php on line 121
Here is line 121:
<?php if (($_smarty_tpl->tpl_vars['SHOWMOGI']->value == 1)) {?>
<span style="margin: 0 0 0 20px"><?php echo l10n('Metadata Open Graph link image');?>
</span>
Offline
Could it be that the problem is not related to the Metadata Open Graph plugin?
Offline
Hi :-)
in file mog_adminphoto.tpl can you replace line 76
{if ($SHOWMOGI==1)}
by
{if isset($metagestion) and ($SHOWMOGI==1)}
Offline
Hi ddtddt,
With {if isset($metagestion) and ($SHOWMOGI==1)}, the error is gone in my log file.
Offline