[pmwiki-users] Re: Re: Blog proposal
Patrick R. Michaud
pmichaud at pobox.com
Thu Dec 15 14:46:59 CST 2005
On Thu, Dec 15, 2005 at 03:37:35PM -0500, Waylan Limberg wrote:
> Which brings to mind the one thing I havn't seen dicussed. Supose an
> admin want to restrict blog posts to a tighter naming scheme that
> PmWiki's defaults. Any idea's how one would do so? Perhaps some more
> $Fmt type variables (bad example: $BlogPostNameFmt = ${Name}; or
> something like that)
Probably something like:
if ($action=='edit'
&& $_POST['post']
&& strpos($_POST['text'], '(:blog') !== false
&& !preg_match('/\\.\\d+$/', $pagename)) {
$EnablePost = 0;
$MessagesFmt[] = "Cannot post a blog entry for non-numeric pagenames";
}
Pm
More information about the pmwiki-users
mailing list