[pmwiki-users] Author field and usernames problem
Patrick R. Michaud
pmichaud at pobox.com
Mon Jan 22 11:21:53 CST 2007
On Mon, Jan 22, 2007 at 06:06:59PM +0100, Michele Cabano wrote:
> Patrick R. Michaud wrote:
> > If you want the Author name to always exactly follow the username
> > login value, then use the following sequence:
> >
> > include_once('scripts/authuser.php');
> > if (@$AuthId) $Author = $AuthId;
> >
> > See http://www.pmwiki.org/wiki/Cookbook/RequireAuthor for more details.
> >
> > Pm
> >
>
> Thanks for the reply.
>
> I modified config.php like above, but the problem still exists.
> I also noticed that if I write someting containing non-alphanumeric
> characters in the author field (like 'john..smith' or 'john/smith')
> modifications are assigned in every case to 'johnsmith'
Yes -- In certain instances PmWiki automatically converts author
names into something that can be used as a valid pagename
(by eliminating the dots and/or slashes). But it shouldn't
do this if you're explicitly setting the $Author variable --
in that case PmWiki leaves the variable alone.
Note that the above only sets the author name when someone
has logged in with a username and password -- if a person hasn't
logged in the author names continue to work as before (i.e.,
coming from a browser cookie).
If you just want PmWiki to allow any character in author names,
you might try setting (note the leading space):
$AuthorNameChars = " -\\xff";
Pm
More information about the pmwiki-users
mailing list