[pmwiki-users] Undefined array key "title" in .../grouptitle.php - in PHP8

Hans-Jürgen Godau juergen at godau-witten.de
Sun Feb 20 03:51:30 PST 2022


I just would try using the line

*if (array:key:exists('title',$page) && $page['title']) { return
$page['title'];*

I think in php 8 a non existing key throws this Warning!

Greetings,
jürgen

Am Sa., 19. Feb. 2022 um 11:28 Uhr schrieb Jean-Patrick Charrey <
jpcharrey at free.fr>:

> Hi
>
> I have been testing the latest Pmwiki 2.3.2 on PHP8.0  I have the
> following warning message:
>
> *Warning*: Undefined array key "title" in *.../cookbook/grouptitle.php* on
> line *39*
>
> I have been to reproduce this bug on a plain setup, no other cookbooks,
> default PMwiki skin.
> I don't have this message in PHP7.4
>
> Line 39 in grouptitle.php has the following code
>
> *    if ($page['title']) { return $page['title'];*
>
> I guessing a sintax update is needed, but not sure which one. I realize
> this Cookbook is perhaps not the most used, but I would appreciate some
> help to fix this issue.
> Jean-Patrick
> _______________________________________________
> pmwiki-users mailing list
> pmwiki-users at pmichaud.com
> http://www.pmichaud.com/mailman/listinfo/pmwiki-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.pmichaud.com/pipermail/pmwiki-users/attachments/20220220/10d9aa6c/attachment.html>


More information about the pmwiki-users mailing list