Title |
Test
Find
yyyy-mm-dd hh:mm
|
Expression |
^((\d{2}(([02468][048])|([13579][26]))[-]?((((0?[13578])|(1[02]))[-]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[-]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[-]?((0?[1-9])|([1-2][0-9])))))|(\d{2}(([02468][1235679])|([13579][01345789]))[-]?((((0?[13578])|(1[02]))[-]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[-]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[-]?((0?[1-9])|(1[0-9])|(2[0-8]))))))(\s((([0-1]?[0-9])|([2][0-3]))\:([0-5][0-9])))?$ |
Description |
This expression will validate date format to be yyyy-mm-dd hh:mm. |
Matches |
2009-12-30 00:00 | 2009-02-30 00:00 | 2009-12-30 12:00 |
Non-Matches |
2009 10 10 23:59 | 2009-10-10 25:50 | 2009 10 10 23:59 |
Author |
Rating:
Not yet rated.
Kiran Patil
|
Source |
|
Your Rating |
|