Module: Username Restrictions
Posted by Maurice Makaay
|
Module: Username Restrictions May 18, 2007 05:31PM |
Admin Registered: 22 years ago Posts: 8,532 |
This module implements features for enforcing user name restrictions. The module will check the user name at registration time and show an error to the user if the new username does not meet the restrictions.
Implemented features are:
* Minimum username length;
* Maximum username length;
* Configuration of valid characters for usernames;
* Only allow lower case characters for usernames.
These features can be separately enabled and disabled through the module's settings screen.
If you have additional ideas for username restrictions or if you translated the language file to a new language, then please post in this thread.
Maurice Makaay
Phorum Development Team
my blog
linkedin profile
secret sauce
Edited 1 time(s). Last edit at 05/18/2007 05:44PM by mmakaay.
Implemented features are:
* Minimum username length;
* Maximum username length;
* Configuration of valid characters for usernames;
* Only allow lower case characters for usernames.
These features can be separately enabled and disabled through the module's settings screen.
If you have additional ideas for username restrictions or if you translated the language file to a new language, then please post in this thread.
Maurice Makaay
Phorum Development Team
my blog
linkedin profile
secret sauceEdited 1 time(s). Last edit at 05/18/2007 05:44PM by mmakaay.
|
Re: Module: Username Restrictions May 19, 2007 03:19PM |
Registered: 21 years ago Posts: 46 |
Hello Maurice,
this mod is a nice idea :-)
Min and max are very needed.
I have a problem with the languagefile: i can't type in an AMBERSAND "&". so i could not make an vallide german languagefile :-(
One idea: The first letter and letters follow a blank or hyphen only allows like Maurice Makaay or Jean-Claude van Damme
Greethings
Berti
I speek swabian and german very well - not english :-(
My Phorum on [clever-forum.de]
My testfforum with version 5.2.x is on [test.clever-forum.de] (user: Phorum password: Clever)
this mod is a nice idea :-)
Min and max are very needed.
I have a problem with the languagefile: i can't type in an AMBERSAND "&". so i could not make an vallide german languagefile :-(
One idea: The first letter and letters follow a blank or hyphen only allows like Maurice Makaay or Jean-Claude van Damme
Greethings
Berti
I speek swabian and german very well - not english :-(
|
Re: Module: Username Restrictions June 08, 2007 07:13AM |
Admin Registered: 22 years ago Posts: 8,532 |
The problem lies in the register.php script, which does some superfluous html character escaping. I fixed this in the code, so the next Phorum release will have the fix in it. For now, you will have to open register.php and search for:
About the idea: I'll think about it. Maybe some rules like "must start with a letter", "must end with a letter" and "no more than one special character in a row" could be useful for this.
Maurice Makaay
Phorum Development Team
my blog
linkedin profile
secret sauce
$PHORUM["DATA"]["ERROR"] = htmlspecialchars($error);Replace this line with:
$PHORUM["DATA"]["ERROR"] = $error;This change will fix your language file problems.
About the idea: I'll think about it. Maybe some rules like "must start with a letter", "must end with a letter" and "no more than one special character in a row" could be useful for this.
Maurice Makaay
Phorum Development Team
my blog
linkedin profile
secret sauce
|
Re: Module: Username Restrictions June 12, 2007 08:47AM |
Admin Registered: 20 years ago Posts: 747 |
Hi Maurice, Hi Berti,
the German Language Files Package 1.3 supports now also the Username Restrictions Module.
@Maurice: perhaps you want to include the attached files in your distribution.
Regards
Oliver
Using Phorum since 7/2000: forum.langzeittest.de (actual version 5.2.23)
Modules "Made in Germany" for version 5.2: Author_as_Sender, CarCost, Close_Topic, Conceal_Message_Timestamp,
Format_Email, Index_Structure, Mailing_List, Pervasive_Forum, Spritmonitor, Terms_of_Service and German_Language_Files_Package.
Edited 1 time(s). Last edit at 06/12/2007 09:12AM by Oliver Riesen.
the German Language Files Package 1.3 supports now also the Username Restrictions Module.
@Maurice: perhaps you want to include the attached files in your distribution.
Regards
Oliver
Using Phorum since 7/2000: forum.langzeittest.de (actual version 5.2.23)
Modules "Made in Germany" for version 5.2: Author_as_Sender, CarCost, Close_Topic, Conceal_Message_Timestamp,
Format_Email, Index_Structure, Mailing_List, Pervasive_Forum, Spritmonitor, Terms_of_Service and German_Language_Files_Package.
Edited 1 time(s). Last edit at 06/12/2007 09:12AM by Oliver Riesen.
|
Re: Module: Username Restrictions February 29, 2008 07:59AM |
Registered: 19 years ago Posts: 62 |
hi all,
i've installed phorum 5.2 and activated the mod username restrictions. it seems, that it is not possible to limit the minimum
username length and let the maximum length unlimited. if i set a number greater than 0 for the min length and a 0 for the max number, the max number is changed from 0 to the min length setting.
to avoid that behaviour, line 31ff of settings.php should be changed from
if ($settings["max_length"] < $settings["min_length"]) {
$settings["max_length"] = $settings["min_length"];
}
to
if (($settings["max_length"] < $settings["min_length"]) && ($settings["max_length"] != 0))
{
$settings["max_length"] = $settings["min_length"];
}
or something similar.
i've installed phorum 5.2 and activated the mod username restrictions. it seems, that it is not possible to limit the minimum
username length and let the maximum length unlimited. if i set a number greater than 0 for the min length and a 0 for the max number, the max number is changed from 0 to the min length setting.
to avoid that behaviour, line 31ff of settings.php should be changed from
if ($settings["max_length"] < $settings["min_length"]) {
$settings["max_length"] = $settings["min_length"];
}
to
if (($settings["max_length"] < $settings["min_length"]) && ($settings["max_length"] != 0))
{
$settings["max_length"] = $settings["min_length"];
}
or something similar.
|
Re: Module: Username Restrictions February 29, 2008 08:36AM |
Admin Registered: 22 years ago Posts: 8,532 |
I added the patch in changeset 3141. Please check if this one fixes it for you. I currently had no time to test the changes out (I'm at a conference and sneaked the update into the tree ;-).
Maurice Makaay
Phorum Development Team
my blog
linkedin profile
secret sauce
Maurice Makaay
Phorum Development Team
my blog
linkedin profile
secret sauce
|
Re: Module: Username Restrictions October 07, 2013 08:17PM |
Registered: 13 years ago Posts: 23 |
Please note that v. 1.0.2 of the "Username Restrictions" mod is included in Phorum v. 5.2.19. Thanks for that!!
However, say you don't want <swear word> to appear in user names, you can now prevent it with v. 1.0.3 of this "Username Restrictions" mod - attached hereto - mod of the mod coded by Skinny. It was a small mod - no biggie - but can prevent yucky user names or user names resembling things like "admin" or "<domain>" or whatever you want.
For example, should someone try and register with foo<swear word>bar or big<swear word> or <swear word>bad, and <swear word> is on your word bit list, said user won't be able to register and instead will be told...
"<swear word>" was found in your username but is not allowed. Please choose something else.
nJoy!!
However, say you don't want <swear word> to appear in user names, you can now prevent it with v. 1.0.3 of this "Username Restrictions" mod - attached hereto - mod of the mod coded by Skinny. It was a small mod - no biggie - but can prevent yucky user names or user names resembling things like "admin" or "<domain>" or whatever you want.
For example, should someone try and register with foo<swear word>bar or big<swear word> or <swear word>bad, and <swear word> is on your word bit list, said user won't be able to register and instead will be told...
nJoy!!
|
Re: Module: Username Restrictions January 13, 2014 05:06PM |
Registered: 20 years ago Posts: 99 |
Hello All,
I realized this is an old version but I still use it. I have translated it in French, for those interested.
Please not that on my system, I had to replace " with the real ", in the language file so it would correctly show on my forum.
Regards,
Yves
I realized this is an old version but I still use it. I have translated it in French, for those interested.
Please not that on my system, I had to replace " with the real ", in the language file so it would correctly show on my forum.
Regards,
Yves
Sorry, only registered users may post in this forum.