Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Restrict member from signing up with the word "admin" as username
htweet1
New
Please how do i restrict members from signing up with the word "admin" as username?
0
Comments
what do you mean by signing up? do you mean registering (new account) or signing (logging) in?
you said you were enlightened, yet, still pose ambiguous question (at least to me).
is it not clear?
http://vanillaforums.org/discussion/comment/234548/#Comment_234548
if you mean registering.
if you mean signing in.
I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.
I don't mean to confuse anyone with my questions @peregrine and thanks for always being quick to provide answers to all my questions.
If register is synonymous to sign up then I guess signing in is synonymous to registering.
In my question above, I mean restricting members from registering with the word "admin" as username. Thanks for your answer. I'll do just that.
@htweet1 You could override the ValidateUsername function in your bootstrap early file to black list any number of words. I posted a simple example function below, but all you need to do is return false if there is any match for your list. If it makes it past your black list, you could then do the standard validation:
Search first
Check out the Documentation! We are always looking for new content and pull requests.
Click on insightful, awesome, and funny reactions to thank community volunteers for their valuable posts.