[pmwiki-users] Recipes you use/need to be updated for PHP 5.5

Petko Yotov 5ko at 5ko.fr
Sun Jan 5 03:09:34 CST 2014

John Rankin writes:

> > John Rankin writes:
> >> >> >   http://www.pmwiki.org/wiki/PmWiki/CustomMarkup#php55
> >>
> >> By my reading of the link above, all calls to Markup with a /e modifier
> >> will stop working under 2.2.56, yes?
> >
> > Not at all - every time I write about this I repeat that the existing ways
> > will NOT stop working. We ADDED a new way to define markup rules, the old
> > one stays.
> >
> > Under PHP 5.5, the old way will trigger a warning for a deprecated usage.
> > That's why we added a new way for those who need it.
> Ah, I was relying on the link above, which states (emphasis added):
>   The following is acceptable for PHP 5.5+ and PmWiki 2.2.56+
>     Markup($name, $when, $pattern, $replace);
>       '''''$pattern can no longer have an "/e" modifier'''''
> I read that as meaning an existing call to Markup with a /e modifier would
> break. Thanks for the clarification.

Yes, with many warnings it may appear broken for PHP 5.5. Before PHP 5.5 all  
existing rules do not require modification, they work as they always did.  

The "PmWiki 2.2.56+" part meant that you can also use a callback and not  
only a string as replacement from that version on.

The examples in that section marked as "For PHP 5.4 and older, this is  
acceptable:" use the old way with /e which is acceptable.

English is my third language so don't hesitate to edit the page and make it  
more understandable.


More information about the pmwiki-users mailing list