1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Implemented [Suggestion] Username illegal characters

Discussion in 'Closed Suggestions' started by Shamil, Sep 5, 2010.

  1. Shamil

    Shamil Well-Known Member

    I think it'd be useful, and for security measures, if the usernames are restricted by regex, or some other mechanism.

    I'm sure there was a thread on this, can't find it now though.
     
  2. DSF

    DSF Well-Known Member

    Standard-regex is ok.
    The problem are languages in far east. How will you solve this?
     
  3. Mike

    Mike XenForo Developer Staff Member

    You can limit by regex.
     
    Walter and CyberAP like this.
  4. DSF

    DSF Well-Known Member

    Inside the core or via "ACP"? Hope "ACP" ... ;)
     
  5. Mike

    Mike XenForo Developer Staff Member

    Via the admin CP. Limiting via regex in the code wouldn't be very helpful. :)
     
    Enigma, Shadab and DSF like this.
  6. Dean

    Dean Well-Known Member

    regex = ?

    format string similar to vb3.x disallowed names string?
     
  7. TrixieTang

    TrixieTang Well-Known Member

    Kier posted a pic of this in the ACP in another thread... I just don't remember which thread.
     
  8. Shadab

    Shadab Well-Known Member

    RegEx = Regular Expression
    Some very simple regular expressions to limit the usernames are:
    • /^[a-z]+$/i (only alphabets allowed)
    • /^[a-z\s]+$/i (alphabets & spaces allowed)
    • /^[a-z0-9]+$/i (alphanumeric characters only)
    • /^[a-z0-9\s]+$/i (alphanumeric & spaces)
     
    Abomination likes this.
  9. Dean

    Dean Well-Known Member

    Thank you!

    Is there any way to use that to specify other names which should not be used? Currently we have ".com" and many other names prohibited, I won't type those out here.
     
  10. Shamil

    Shamil Well-Known Member

    This is alread there. Kier made a post somewhere with the image
     
    Abomination likes this.
  11. Dean

    Dean Well-Known Member

    Thanks!
     
  12. Shamil

    Shamil Well-Known Member

    Abomination likes this.
  13. Shadab

    Shadab Well-Known Member

  14. Sami

    Sami Well-Known Member

    A hint there. :)
     
  15. TrixieTang

    TrixieTang Well-Known Member

    I think that was completely unrelated to this, he was talking about the Have you seen? post about Style Properties.
     
  16. Sami

    Sami Well-Known Member

    Hmm, that might be. Never mind then. :p
     
  17. Vladislav Rastrusny

    Vladislav Rastrusny Active Member

    Regexes will get compicated if you will want to allow some international characters like Russian letters, for example.
     
  18. Cezz

    Cezz Well-Known Member

    Seems to be a problem with links and quoting again... the link in the quote by Shadab is missing the /community/ bit
     

Share This Page