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

Please support RegExLib Sponsors

Sponsors

Expressions by User

   Displaying page 1 of 1 pages; Items 1 to 2
Title Test Details Date dd-mm-yyyy with leap year
Expression
^(((0[1-9]|[12]\d|3[01])[\s\.\-\/](0[13578]|1[02])[\s\.\-\/]((19|[2-9]\d)\d{2}))|((0[1-9]|[12]\d|30)[\s\.\-\/](0[13456789]|1[012])[\s\.\-\/]((19|[2-9]\d)\d{2}))|((0[1-9]|1\d|2[0-8])[\s\.\-\/]02[\s\.\-\/]((19|[2-9]\d)\d{2}))|(29[\s\.\-\/]02[\s\.\-\/]((1[6-9]|[2-9]\d)(0[48]|[2468][048]|[13579][26])|((16|[2468][048]|[3579][26])00))))$
Description
Checks date in format dd-mm-yyyy. Seperation characters can be -/. and space. dd and mm HAVE to be two characters. Year has to be four characters and minimum 1900. Expression handles leap year as well
Matches
20-02-1975 | 20.02.1975 | 20/02/1975 | 20 02 1975 | 20-12/1975
Non-Matches
20-12-1899 | 29-02-2002 | 28-2-2008
Author Rating: The rating for this expression. Dennis Betten
Title Test Details Dutch Phonenumber
Expression
^((((0031)|(\+31))(\-)?6(\-)?[0-9]{8})|(06(\-)?[0-9]{8})|(((0031)|(\+31))(\-)?[1-9]{1}(([0-9](\-)?[0-9]{7})|([0-9]{2}(\-)?[0-9]{6})))|([0]{1}[1-9]{1}(([0-9](\-)?[0-9]{7})|([0-9]{2}(\-)?[0-9]{6}))))$
Description
Check Dutch phonenumber including 0031 or +31 and optional - characters. I know it can be shortened, but for readability (and shortage of time ;-)) I kept it like it is...
Matches
0031612345678 | 0031-6123456789 | 0031-6-123456789 | 0031-50-1234567 | 0031-592-123456 | +31612345678 | 0612345678 | 06-12345678 | 050-1234567 | 0592-123456
Non-Matches
+31(0)612345678 | 06123456789 | 00310612345678 | 0031-6-123-45678
Author Rating: The rating for this expression. Dennis Betten
   Displaying page 1 of 1 pages; Items 1 to 2

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