[pmwiki-users] Cookbook MarkupExprPlus

Hans design at bracker.uk
Tue Nov 12 05:17:24 PST 2019

Hello Dominique,
when using any of the arithmetic Markup Expressions from
MarkupExprPlus https://www.pmwiki.org/wiki/Cookbook/MarkupExprPlus
it is throwing error on PHP 7.2:
"Deprecated: Function create_function() is deprecated in ...pmwiki.php on line 499"

I can see from the code in markupexprplus.php that the arithmetic MEs
using PPRE() calls, which leads to PCCF() calls, which leads to the
error. Is this fixable?
The recipe is flagged to be PHP 7.2 compatible, but apparently it is

For my very simple purposes I could substitute the arithmetic MEs
with some very simple code:
$MarkupExpr['add'] = '$args[0] + $args[1]';
$MarkupExpr['sub'] = '$args[0] - $args[1]';
$MarkupExpr['mul'] = '$args[0] * $args[1]';
$MarkupExpr['div'] = '$args[0] / $args[1]';

but the MarkupExprPlus MEs allowed for more complex expressions.

Best regards,

More information about the pmwiki-users mailing list