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

Please support RegExLib Sponsors

Sponsors

Regular Expression Details

Title Test Find Date validation
Expression
\b([0]?[1-9]|[1,2]\d|3[0,1])[-/]([0]?[1-9]|[1][0,1,2])[-/](\d{1,2}|[1][9]\d\d|[2][0]\d\d)\b
Description
Validates strings of type dd/mm/yyyy. checking dd to be between 1-31, mm between 1-12 and yyyy between 1900-2099.
Matches
1/1/1900 | 31/12/10 | 20/1/1010
Non-Matches
33/1/1900 | 1/13/1800 | 1/1/987
Author Rating: Not yet rated. Alex Manetas
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

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