miniBB ®  
miniBB Support Forums
 | Forums | Register | Reply | Search | Statistics | Manual | miniBB Mobile
How To miniBB Support Forums / How To /   

Limit username length to minimum 2 characters (also as the maximum)

Author Patrick
Guest
#1 | Posted: 9 Sep 2005 10:43 
Hi which file has the information on how many characters a username can have. Right now, i believe you need to have more than 3 letters i'd like to set this to 2 letters.
Author Team
8-)
#2 | Posted: 9 Sep 2005 10:44 
bb_func_checkusr.php

Change $userRegExp="#^[".$userRegName."]{3,40}\$#";

istead of "3" type "2".
Author michael1234
Registered
#3 | Posted: 15 Aug 2006 19:28 
Any way to limit the amount of letters in a username?
Author Paul
CEO
#4 | Posted: 16 Aug 2006 08:03 
user_dataform.html - limit maxlength of the login field here.
bb_func_checkusr.php - limit {3,40} to {3,MAXLENGTH} here.
Author michael1234
Registered
#5 | Posted: 18 Aug 2006 01:26 
Thank you Paul.
Author otto
Registered
#6 | Posted: 2 Feb 2007 07:18 
Thank you Paul.
Author Paul
CEO
#7 | Posted: 2 Feb 2007 11:32 
My little addition - if you change the script above, it will be still a core-destructive solution.

However, it's more than simple to change "login" field's maxlength in templates/user_dataform.html for example, also as "user_usr" in templates/user_login_form.html. Of course an experienced "hacker" will be able to register longer username, if you don't change bb_func_checkusr.php. But for 95% of users it won't be an easy and even possible task ;-)
How To miniBB Support Forums / How To / Limit username length to minimum 2 characters (also as the maximum) Top
Your Reply Click this icon to move up to the quoted message
 Short link for this topic:

 ?
You are welcome to post anonymously, by entering a nickname with no password (if the similar Username has not been taken yet), or by leaving both fields empty. If you have a forums account, you can also sign in from this page without posting a message, or sign in and post at once.


Before posting, make sure your message is compliant with our forum posting rules. If not, it may be locked or deleted with no explanation.

 
miniBB Support Forums Powered by Forum Software miniBB ® Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contacts
  Organize opinions on miniBB-forums,
collecting them with the Polls & Surveys add-on!
Polls addon for miniBB