locked
regular expression for user name RRS feed

  • Question

  • User-979703773 posted

    i need regular expression that accept a-z, A-z, @, - ,_ 

    Thursday, October 10, 2013 2:46 AM

Answers

  • User-1965857832 posted

    Try this

    ^[a-zA-Z@_-]+$

    If u wanna add restriction on number of characters in it, say should be b/w 4 & 8 try this

    ^[a-zA-Z@_-]{4,8}$




    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, October 10, 2013 4:04 AM