Title |
Test
Find
date expression
|
Expression |
^(((((0?[1-9]|[12]\d|3[01])[-/]([0]?[13578]|1[02]))|((0?[1-9]|[12]\d|30)[-/]([0]?[469]|11))|(([01]?\d|2[0-8])[-/]0?2))[-/]((20|19)?\d{2}|\d{1,2}))|(29[-/]0?2[-/]((19)|(20))?([13579][26]|[24680][048])))$ |
Description |
matches dates in the format day/month/year.
supports / and - charachters.
easily modified to suit your needs.
handles leap years. |
Matches |
1/1/1 01/1/1 11/1/1 1/01/1 1/12/01 1/1/2001 31/1/2001 30/4/1 29/2/00 29/02/2004 |
Non-Matches |
0/1/1 00/5/2001 40/5/2000 31/4/2000 29/2/2001 30/2/2000 1/14/2000 1/0/2000 1/00/2000 1/1/201 1/1/0001 |
Author |
Rating:
Not yet rated.
fake
|
Source |
|
Your Rating |
|