Results 1 to 2 of 2

Thread: Regular expression

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Aug 2004
    Posts
    94

    Regular expression

    I copied an expression on the site www.regexlib.com

    Thats the expression :

    ^(?=.*[0-9]+.*)(?=.*[a-zA-Z]+.*)[0-9a-zA-Z]{6,}$

    So a password must contain at least one letter, at least one number, and be longer than six characters.

    I tested on the site and it seems to work fine, but when I try it on my ASP.net page, something strange happens...

    "aB1234" or "aB1234A" are not accepted, but "aB1234AB" is allright ? It's not even the number of characters, because "1234abcde" isn't accepted too ("1234abcdef" if OK) !

    What's the problem ?

  2. #2

    Thread Starter
    Lively Member
    Join Date
    Aug 2004
    Posts
    94

    Re: Regular expression

    Nobody ?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width