RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Regular Expression Details

Title Test Find password without using lookaheads
Expression
^(.{0,}(([a-zA-Z][^a-zA-Z])|([^a-zA-Z][a-zA-Z])).{4,})|(.{1,}(([a-zA-Z][^a-zA-Z])|([^a-zA-Z][a-zA-Z])).{3,})|(.{2,}(([a-zA-Z][^a-zA-Z])|([^a-zA-Z][a-zA-Z])).{2,})|(.{3,}(([a-zA-Z][^a-zA-Z])|([^a-zA-Z][a-zA-Z])).{1,})|(.{4,}(([a-zA-Z][^a-zA-Z])|([^a-zA-Z][a-zA-Z])).{0,})$
Description
Passwords with at least 1 letter, at least 1 non-letter, and at least 6 characters in length. It is lenthy with a repeating pattern so that I could validate all three conditions in one expression without using a lookahead, "?=", which are not handled correctly in Internet Explorer.
Matches
12345a | abcde* | ABC123
Non-Matches
12ab | abcdef | 123456
Author Rating: The rating for this expression. Brian S
Source
Your Rating
Bad Good

Enter New Comment

Title

Name

Comment

Spammers suck - we apologize. Please enter the text shown below to enable your comment (not case sensitive - try as many times as you need to if the first ones are too hard):

Existing User Comments

Title: ApartHotels Leeds - http://www.gatewayapartments.co.uk/
Name: ApartHotels Leeds - http://www.gatewayapartments.co.uk/
Date: 5/11/2016 10:39:43 AM
Comment:
Apart Hotels Leeds- Self Catering and Serviced Apartments Serviced apartments Leeds- http://www.gatewayapartments.co.uk/ ApartHotels Leeds - http://www.gatewayapartments.co.uk/ Gateway Apartments offer fully furnished Serviced Apartments


Copyright © 2001-2024, RegexAdvice.com | ASP.NET Tutorials