Displaying page
of
pages;
Items to
Title |
Test
Details
Date RegEx Pattern
|
Expression |
(((19|20)([2468][048]|[13579][26]|0[48])|2000)/02/29|((19|20)[0-9]{2}/(0[469]|11)/(0[1-9]|[12][0-9]|30)|(19|20)[0-9]{2}/(0[13578]|1[02])/(0[1-9]|[12][0-9]|3[01])|(19|20)[0-9]{2}/02/(0[1-9]|1[0-9]|2[0-8])))
|
Description |
Very secure RegEx pattern control for your date entries in english/us format YYYY/MM/DD or YYYY-MM-DD (very easy to only authorize / or -).
28,29,30,31 days month are controled according to the month & leap year.
Check it ! Tested and functionnal !
|
Matches |
2016-02-29 | 2012-04-30 | 2019/09/31
|
Non-Matches |
2016-02-30 | 2012-04-31 | 2019/09/35
|
Author |
Rating:
Arthur LORENT
|
Title |
Test
Details
MySQL datetime RegEx Pattern
|
Expression |
((((19|20)([2468][048]|[13579][26]|0[48])|2000)-02-29|((19|20)[0-9]{2}-(0[469]|11)-(0[1-9]|[12][0-9]|30)|(19|20)[0-9]{2}-(0[13578]|1[02])-(0[1-9]|[12][0-9]|3[01])|(19|20)[0-9]{2}-02-(0[1-9]|1[0-9]|2[0-8])))\s([01][0-9]|2[0-3]):([012345][0-9]):([012345][0-9]))
|
Description |
Very secure MySQL datetime RegEx pattern control.
Strictly allow the following format only :
"YYYY-MM-DD HH:MM:SS"
Verify if date is correct (28,29,30,31 days accoring to the month. Leap years with 29/02 also controled.
|
Matches |
2013-04-05 17:59:59 | 2013-07-30 01:22:42 | 2099-12-30 23:59:59 | 2016-02-28 00:00:00
|
Non-Matches |
2016-02-29 -01:01:02 | 3000-04-24 17:42:21 | 2012-03-03 24:24:02 | 2012-03-03 21:60:45
|
Author |
Rating:
Arthur LORENT
|
Displaying page
of
pages;
Items to