[pmwiki-users] APE config.php error/fix in PHP 8.4

Moni Kellermann kellerfrau at gmail.com
Wed Feb 11 08:21:50 PST 2026


Hi,

I am testing the latest PmWiki (2.56) on the latest XAMPP Lite 
(https://sourceforge.net/projects/xampplite/files/8.4/8.4.6/).

Adding APE to the config.php with

if($action=="browse" || !empty(@$_REQUEST['preview'])) {
   include_once("$FarmD/cookbook/ape.php");
}

now throws a "Warning: Undefined array key "preview"

This seems to happen due to the change listed here:
https://www.php.net/manual/en/migration80.incompatible.php

where it states "The ability to use array_key_exists() with objects has 
been removed. isset() or property_exists() may be used instead."

Therefore I changed the code to

if($action=="browse" || isset($_REQUEST['preview'])) {
   include_once("$FarmD/cookbook/ape.php");
}

This works.

Kind regards,
moni k.





More information about the pmwiki-users mailing list