3 Adds an input box on the edit/ page, that allows users to set an
4 author name individually. Would allow to override the username
5 string, if one was already set by ProtectedMode plugins (but of
6 course this is no permission problem).
8 NOTE: we need to incorporate some password awareness in here, so
9 this can be used, even if user/prof extensions are present and
10 certain usernames were registered already (pw in name HomePages).
14 define("EWIKI_UP_AUTHOR_NAME", "author_name");
18 $ewiki_plugins["edit_form_append"][] = "ewiki_aedit_authorname";
19 function ewiki_aedit_authorname($id, &$data, $action) {
21 $var = EWIKI_UP_AUTHOR_NAME;
22 return(ewiki_t(<<< EOT
24 _{set the AuthorName to} <input size="20" name="$var" value="$GLOBALS[ewiki_author]">
31 #-- store as cookie (for 1 month)
32 if ($uu = @$_REQUEST[EWIKI_UP_AUTHOR_NAME]) {
34 if (!strpos($uu, "://")) {
37 if ($_COOKIE[EWIKI_UP_AUTHOR_NAME] != $ewiki_author) {
38 setcookie(EWIKI_UP_AUTHOR_NAME, $ewiki_author, time()+2500000);