[pmwiki-users] Fix blogit for use with PHP 5.5
pmwiki at solidgone.com
Thu Oct 30 16:41:42 CDT 2014
On 10/30/2014 1:58 PM, Tiger!P wrote:
>>> This does not result in the error message, but when I go to the new blog
>>> page (/Site/BlogIt-Admin?action=bi_ne ) some blogit codes are displayed
>>> on the page. I don't know if this was the case before PHP5.5, but don't
>>> think so.
>>> Blog Title: (:blogit list "$:entrytype":)bi_PageType/Type:
>>> (:blogitend:)(:blogit list "$:blogid":)bi_BlogList/BlogID: (:blogitend:)
>>> Tags: (:blogit list "$:entrystatus":)bi_StatusType/Status:
>>> (:blogitend:)(:blogit list "$:entrycomments":)bi_CommentType/Comments:
> This problem still exists.
> And now the /Blog/Main page does not have any blog posts anymore. Also
> the list of recently written is empty.
> But the Categories contains a list of tags and when I select a tag, I
> see a link to the blogpost which has that tag.
> So I think something is not quite right yet.
> Hopefully DaveG can give some advice.
I suspect this error is not related to PHP5. I've applied your patches,
and the test site seems to work (ref http://wiki.solidgone.org/BlogIt/Main).
For others testing this out, ensure you have updated to the latest
version of PMWiki, load the new version of PmForms, ensure your skin is
PHP5 compatible, and ensure other cookbooks you include are also compatible.
1. Tiger!P: With your patch file, why are you making the change to
$PageTextVarPatterns, from #blogit_(\w[_-\w]*) to #blogit_(\w[_\w-]*)?
2. All: Is there a preference to using Markup_e over Markup? I went
ahead and used anon functions with Markup, just to make things
3. All: Any suggestions for this:
$bodyTags = (preg_match_all('/\[\[\!(.*?)\]\]/e', $body, $match)
To be honest I'm not entirely sure why the e modifier is used there,
but assuming it's needed, do we have Pm helper functions for preg_match_all?
~ ~ David
More information about the pmwiki-users