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

Please support RegExLib Sponsors

Sponsors

Advanced Search

Keywords

Category

Minimum Rating

Results per Page

Search Results: 3933 regular expressions found.

Change page:   |    Displaying page 27 of 40 pages; Items 2601 to 2700
Title Test Details M/d/y Date
Expression
^(?:(?:(?:0?[13578]|1[02])(\/|-|\.)31)\1|(?:(?:0?[13-9]|1[0-2])(\/|-|\.)(?:29|30)\2))(?:(?:1[6-9]|[2-9]\d)?\d{2})$|^(?:0?2(\/|-|\.)29\3(?:(?:(?:1[6-9]|[2-9]\d)?(?:0[48]|[2468][048]|[13579][26])|(?:(?:16|[2468][048]|[3579][26])00))))$|^(?:(?:0?[1-9])|(?:1[0-2]))(\/|-|\.)(?:0?[1-9]|1\d|2[0-8])\4(?:(?:1[6-9]|[2-9]\d)?\d{2})$
Description
This expression validates dates in the US m/d/y format from 1/1/1600 - 12/31/9999.
Matches
01.1.02 | 11-30-2001 | 2/29/2000
Non-Matches
02/29/01 | 13/01/2002 | 11/00/02
Author Rating: Not yet rated. Michael Ash
Title Test Details DateTime M/d/y hh:mm:ss
Expression
^(?=\d)(?:(?:(?:(?:(?:0?[13578]|1[02])(\/|-|\.)31)\1|(?:(?:0?[1,3-9]|1[0-2])(\/|-|\.)(?:29|30)\2))(?:(?:1[6-9]|[2-9]\d)?\d{2})|(?:0?2(\/|-|\.)29\3(?:(?:(?:1[6-9]|[2-9]\d)?(?:0[48]|[2468][048]|[13579][26])|(?:(?:16|[2468][048]|[3579][26])00))))|(?:(?:0?[1-9])|(?:1[0-2]))(\/|-|\.)(?:0?[1-9]|1\d|2[0-8])\4(?:(?:1[6-9]|[2-9]\d)?\d{2}))($|\ (?=\d)))?(((0?[1-9]|1[012])(:[0-5]\d){0,2}(\ [AP]M))|([01]\d|2[0-3])(:[0-5]\d){1,2})?$
Description
DateTime Validator.
Matches
12/25/2003 | 08:03:31 | 02/29/2004 12 AM
Non-Matches
02/29/2003 1:34 PM | 13:23 PM | 24:00:00
Author Rating: The rating for this expression. Michael Ash
Title Test Details Time
Expression
^((0?[1-9]|1[012])(:[0-5]\d){0,2}(\ [AP]M))$|^([01]\d|2[0-3])(:[0-5]\d){0,2}$
Description
This RE validates times patterns.
Matches
1 AM | 23:00:00 | 5:29:59 PM
Non-Matches
13 PM | 13:60:00 | 00:00:00 AM
Author Rating: The rating for this expression. Michael Ash
Title Test Details MMM dd, yyyy Date
Expression
^(?:(((Jan(uary)?|Ma(r(ch)?|y)|Jul(y)?|Aug(ust)?|Oct(ober)?|Dec(ember)?)\ 31)|((Jan(uary)?|Ma(r(ch)?|y)|Apr(il)?|Ju((ly?)|(ne?))|Aug(ust)?|Oct(ober)?|(Sept|Nov|Dec)(ember)?)\ (0?[1-9]|([12]\d)|30))|(Feb(ruary)?\ (0?[1-9]|1\d|2[0-8]|(29(?=,\ ((1[6-9]|[2-9]\d)(0[48]|[2468][048]|[13579][26])|((16|[2468][048]|[3579][26])00)))))))\,\ ((1[6-9]|[2-9]\d)\d{2}))
Description
This RE validate Dates in the MMM dd, yyyy format from Jan 1, 1600 to Dec 31, 9999. The format is as follows: The name or 3 letter abbreivation, without a period, of the month, then a space then the day value then a comma then a space finally the year. The correct number of day are validated for each month include leap years. The name of month is case sensitive.
Matches
Jan 1, 2003 | February 29, 2004 | November 02, 3202
Non-Matches
Feb 29, 2003 | Apr 31, 1978 | jan 33,3333
Author Rating: Not yet rated. Michael Ash
Title Test Details dd MMM yyyy Date
Expression
^((31(?!\ (Feb(ruary)?|Apr(il)?|June?|(Sep(?=\b|t)t?|Nov)(ember)?)))|((30|29)(?!\ Feb(ruary)?))|(29(?=\ Feb(ruary)?\ (((1[6-9]|[2-9]\d)(0[48]|[2468][048]|[13579][26])|((16|[2468][048]|[3579][26])00)))))|(0?[1-9])|1\d|2[0-8])\ (Jan(uary)?|Feb(ruary)?|Ma(r(ch)?|y)|Apr(il)?|Ju((ly?)|(ne?))|Aug(ust)?|Oct(ober)?|(Sep(?=\b|t)t?|Nov|Dec)(ember)?)\ ((1[6-9]|[2-9]\d)\d{2})$
Description
This RE validates dates in the dd MMM yyyy format. Spaces separate the values.
Matches
31 January 2003 | 29 March 2004 | 29 Feb 2008
Non-Matches
Jan 1 2003 | 31 Sept 2003 | 29 February 2003
Author Rating: The rating for this expression. Michael Ash
Title Test Details Months
Expression
^(?:J(anuary|u(ne|ly))|February|Ma(rch|y)|A(pril|ugust)|(((Sept|Nov|Dec)em)|Octo)ber)$
Description
This RE validate the full name of the months.
Matches
January | May | October
Non-Matches
Jan | Septem | Octo
Author Rating: The rating for this expression. Michael Ash
Title Test Details Days of the week
Expression
^(Sun|Mon|(T(ues|hurs))|Fri)(day|\.)?$|Wed(\.|nesday)?$|Sat(\.|urday)?$|T((ue?)|(hu?r?))\.?$
Description
This RE matches Days of the week or their abbreviations.
Matches
Sunday | Mon | Tu
Non-Matches
day | Wedday | Payday
Author Rating: Not yet rated. Michael Ash
Title Test Details ISBN-10
Expression
ISBN\x20(?=.{13}$)\d{1,5}([- ])\d{1,7}\1\d{1,6}\1(\d|X)$
Description
This RE validates the format of an ISBN number
Matches
ISBN 0 93028 923 4 | ISBN 1-56389-668-0 | ISBN 1-56389-016-X
Non-Matches
123456789X | ISBN 9-87654321-2 | ISBN 123 456-789X
Author Rating: Not yet rated. Michael Ash
Title Test Details State Codes
Expression
^(?-i:A[LKSZRAEP]|C[AOT]|D[EC]|F[LM]|G[AU]|HI|I[ADLN]|K[SY]|LA|M[ADEHINOPST]|N[CDEHJMVY]|O[HKR]|P[ARW]|RI|S[CD]|T[NX]|UT|V[AIT]|W[AIVY])$
Description
The RE match U.S. state abbreviation used by the U.S. Post Office.
Matches
AL | CA | AA
Non-Matches
New York | California | ny
Author Rating: The rating for this expression. Michael Ash
Title Test Details U.S. Street Address
Expression
^(?n:(?<address1>(\d{1,5}(\ 1\/[234])?(\x20[A-Z]([a-z])+)+ )|(P\.O\.\ Box\ \d{1,5}))\s{1,2}(?i:(?<address2>(((APT|B LDG|DEPT|FL|HNGR|LOT|PIER|RM|S(LIP|PC|T(E|OP))|TRLR|UNIT)\x20\w{1,5})|(BSMT|FRNT|LBBY|LOWR|OFC|PH|REAR|SIDE|UPPR)\.?)\s{1,2})?)(?<city>[A-Z]([a-z])+(\.?)(\x20[A-Z]([a-z])+){0,2})\, \x20(?<state>A[LKSZRAP]|C[AOT]|D[EC]|F[LM]|G[AU]|HI|I[ADL N]|K[SY]|LA|M[ADEHINOPST]|N[CDEHJMVY]|O[HKR]|P[ARW]|RI|S[CD] |T[NX]|UT|V[AIT]|W[AIVY])\x20(?<zipcode>(?!0{5})\d{5}(-\d {4})?))$
Description
captures US street address. Address format: ##### Street 2ndunit City, ST zip+4 address1 - must have street number and proper case street name. no punctuation or P.O Box #### punctuation manditory for P.O. address2 - optional secondary unit abbr. Secondary range required for some units. City - Proper case city name. State - State abbreviation. All caps zip - zip+4. Can't be all zeroes Abbreviations for secondary units and States are those used by the US Postal Service. http://www.usps.com/ncsc/lookups/usps_abbreviations.html Certain secondary units require a secondary range, see the above link THis RE isn't unbreakable, Probably will allow some false positives but should work for most addresses.
Matches
123 Park Ave Apt 123 New York City, NY 10002 | P.O. Box 12345 Los Angeles, CA 12304
Non-Matches
123 Main St | 123 City, State 00000 | 123 street city, ST 00000
Author Rating: Not yet rated. Michael Ash
Title Test Details XML Tag
Expression
<(\w+)(\s(\w*=".*?")?)*((/>)|((/*?)>.*?</\1>))
Description
This RE will match XML tag elements. All elements must be closed. Won't match nested tags
Matches
&lt;body&gt; text&lt;br/&gt;More Text &lt;/body&gt; | &lt;a href=&quot;link.html&quot;&gt;Link&lt;/a
Non-Matches
&lt;p&gt; Some Text &lt;p&gt; | &lt;hr&gt; | &lt;html&gt;
Author Rating: The rating for this expression. Michael Ash
Title Test Details mm/dd/yyyy hh:MM:ss AM/PM DateTime
Expression
(?n:^(?=\d)((?<month>(0?[13578])|1[02]|(0?[469]|11)(?!.31)|0?2(?(.29)(?=.29.((1[6-9]|[2-9]\d)(0[48]|[2468][048]|[13579][26])|(16|[2468][048]|[3579][26])00))|(?!.3[01])))(?<sep>[-./])(?<day>0?[1-9]|[12]\d|3[01])\k<sep>(?<year>(1[6-9]|[2-9]\d)\d{2})(?(?=\x20\d)\x20|$))?(?<time>((0?[1-9]|1[012])(:[0-5]\d){0,2}(?i:\x20[AP]M))|([01]\d|2[0-3])(:[0-5]\d){1,2})?$)
Description
New DateTime Regex. Rebuilt better than before, better, stronger, faster.
Matches
1/31/2002 10 AM | 2/29/2004 | 4:15:04 PM
Non-Matches
2/29/2003 | 12/32/2003 | 4:00
Author Rating: The rating for this expression. Michael Ash
Title Test Details dd/mm/yyyy hh:MM:ss Datetime
Expression
(?n:^(?=\d)((?<day>31(?!(.0?[2469]|11))|30(?!.0?2)|29(?(.0?2)(?=.{3,4}(1[6-9]|[2-9]\d)(0[48]|[2468][048]|[13579][26])|(16|[2468][048]|[3579][26])00))|0?[1-9]|1\d|2[0-8])(?<sep>[/.-])(?<month>0?[1-9]|1[012])\2(?<year>(1[6-9]|[2-9]\d)\d{2})(?:(?=\x20\d)\x20|$))?(?<time>((0?[1-9]|1[012])(:[0-5]\d){0,2}(?i:\ [AP]M))|([01]\d|2[0-3])(:[0-5]\d){1,2})?$)
Description
DD/MM/YYYY format New DateTime Regex. Rebuilt better than before, better, stronger, faster. This regex will validate a date, time or a datetime. It will also capture the date fields and the time. Dates are in the DD/MM/YYYY format and validated for months, number of days in a month and leap years (29/2) Date field can be separated by matched periods(.), dashes(-) or forward slashes(/). Year range 1600-9999 Time is either 12 hour AM/PM format (HH:mm:ss AM), where minutes and seconds are optional. AM or PM required. or 24 hour military format (HH:mm:SS), from 00:00:00 to 23:59:59, where hours and minutes fields are required, including leading 0 for hours less than 10. Datetime is the above date and time formats separated by a space, with the date first (DD/MM/YYYY HH:mm:SS) !IMPORTANT NOTE: your regex engine must support lookaheads and named groups to use this expression
Matches
31/12/2003 | 29/2/2004 4:50 PM | 23:59:59
Non-Matches
12/31/2003 | 29/2/2003 | 4:00
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
^(?n:(?<lastname>(St\.\ )?(?-i:[A-Z]\'?\w+?\-?)+)(?<suffix>\ (?i:([JS]R)|((X(X{1,2})?)?((I((I{1,2})|V|X)?)|(V(I{0,3})))?)))?,((?<prefix>Dr|Prof|M(r?|(is)?)s)\ )?(?<firstname>(?-i:[A-Z]\'?(\w+?|\.)\ ??){1,2})?(\ (?<mname>(?-i:[A-Z])(\'?\w+?|\.))){0,2})$
Description
This pattern captures &lt;lastname&gt;&lt;suffix&gt;,&lt;prefix&gt;&lt;firstname&gt;&lt;mname&gt; Names must start with a capital letter. Last names may be hyphenated. First names can have two parts ie &quot;Mary Anne&quot; if there are more than two names after the comma. Suffixes can number up to XXX (30th). Standard prefixes are optional (Mr Miss)
Matches
O'Brien, Miles | McDonald,Mary Ann Alison | Windsor-Smith,Barry
Non-Matches
jones, john
Author Rating: The rating for this expression. Michael Ash
Title Test Details Currency
Expression
^(?!\u00a2) #Don't allow cent symbol \p{Sc}? #optional unicode currency symbols (?!0,?\d) #don't allow leading zero if 1 or more unit (\d{1,3} # 1 to 3 digits (\,\d{3})* # if the is a comma it must be followed by 3 digits |(\d+)) # more than 3 digit with no comma separator (\.\d{2})?$ # option cents
Description
This regex validates Currency. The base monetary unit (ex. US dollar) followed by option two digit cent denomination. Base unit can't have leading zero. Comma's are optional on base units. Note: Your regex engine must support the \p character class to use this. For example this will work in .net but not javascript which doesn't support \p Also the &#162; is removed from the match by force. Any other cent symbol would need to be added to the exclude to not match.
Matches
$1,501.13 | &#163;215 | €4.93
Non-Matches
01.00 | $.00 | &#162;50
Author Rating: The rating for this expression. Michael Ash
Title Test Details Quoted string
Expression
^(\x22|\x27)((?!\1).|\1{2})*\1$
Description
The regex validate a quoted string in VBScript or Ansi SQL. The string may contain the containing quote character if it is escaped by being doubled up. In VB/VBScript two double quotes within a string enclosed in double qoutes translate into one double quote within the string In SQL two single quotes within a string enclosed in single qoutes translate into one single quote within the string
Matches
"To quote Yoda (""Do, or do not. There is no 'try'"" )"
Non-Matches
'This won't validate' | "He said "Ok.""
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
^(?=\d)(?:(?:31(?!.(?:0?[2469]|11))|(?:30|29)(?!.0?2)|29(?=.0?2.(?:(?:(?:1[6-9]|[2-9]\d)?(?:0[48]|[2468][048]|[13579][26])|(?:(?:16|[2468][048]|[3579][26])00)))(?:\x20|$))|(?:2[0-8]|1\d|0?[1-9]))([-./])(?:1[012]|0?[1-9])\1(?:1[6-9]|[2-9]\d)?\d\d(?:(?=\x20\d)\x20|$))?(((0?[1-9]|1[012])(:[0-5]\d){0,2}(\x20[AP]M))|([01]\d|2[0-3])(:[0-5]\d){1,2})?$
Description
DateTime Validator. This RE validates both dates and/or times patterns. Days in Feb. are also validated for Leap years. Dates: in dd/mm/yyyy or d/m/yy format between 1/1/1600 - 31/12/9999. Leading zeroes are optional. Date separators can be either matching dashes(-), slashes(/) or periods(.) Times: in the hh:MM:ss AM/PM 12 hour format (12:00 AM - 11:59:59 PM) or hh:MM:ss military time format (00:00:00 - 23:59:59). The 12 hour time format: 1) may have a leading zero for the hour. 2) Minutes and seconds are optional for the 12 hour format 3) AM or PM is required and case sensitive. Military time 1) must have a leading zero for all hours less than 10. 2) Minutes are manditory. 3) seconds are optional. Datetimes: combination of the above formats. A date first then a time separated by a space. ex) dd/mm/yyyy hh:MM:ss This RE is an variation of one of my other Datetime (mm/dd/yyyy) validator already in this library http://www.regexlib.com/REDetails.aspx?regexp_id=369, so the same rules for leap year apply. All 4 digit year and all two digit years except 00, which might not be a leap year.
Matches
31/12/2003 11:59:59 PM | 29-2-2004 | 01:45:02
Non-Matches
12/31/2003 | 29.02.2005 | 13:30 PM
Author Rating: The rating for this expression. Michael Ash
Title Test Details Pattern Title
Expression
,(?!(?<=(?:^|,)\s*\x22(?:[^\x22]|\x22\x22|\\\x22)*,)(?:[^\x22]|\x22\x22|\\\x22)*\x22\s*(?:,|$))
Description
This regex can be used to split the values of a comma delimitted list. List elements may be quoted, unquoted or empty. Commas inside a pair of quotation marks are not matched.
Matches
1,,3""but, wait",5 | 1,2,3
Non-Matches
"Test""a,b,c,d""ing" | no comma | semi; colon
Author Rating: The rating for this expression. Michael Ash
Title Test Details Enitity notation
Expression
& (?ni:\# # if a pound sign follow ampsand look for number ((x # if x follow pound sign accept hex value up to 5 digits ([\dA-F]){1,5} ) | # otherwise accept decimal number between 0 - 1048575 (104857[0-5] |10485[0-6]\d |1048[0-4]\d\d |104[0-7]\d{3} |10[0-3]\d{4} |0?\d{1,6}) ) | # no pound sign after ampersand ([A-Za-z\d.]{2,31}) #accept ASCII alphanumeric and period ); #end with semi-colon.
Description
This regex can be used to find general entites in HTML, XML and SGML files. The entity can consist of 1) an ampsand (&amp;) 2) followed by (a) ASCII alphanumerics or period between 2 and 31 characters or (b) a pound sign # (i) followed by an x followed by a unicode value up to 5 hex digits or (ii) followed by a decimal value from 0 to 1048575 3) ending with a semi-colon (;)
Matches
&quote; | &#169; | &#x00027;
Non-Matches
& | &#Hello; | &#Xray;
Author Rating: Not yet rated. Michael Ash
Title Test Details mm/dd/yyyy Julian and Gregrian Datetime
Expression
(?#Calandar from January 1st 45 BC to December 31, 9999 in mm/dd/yyyy format) (?! (?:10(?<sep>[-./])(?:0?[5-9]|1[0-4])\k<sep>(?:1582))| #Missing days from 1582 (?:0?9(?<sep>[-./])(?:0?[3-9]|1[0-3])\k<sep>(?:1752)) #or Missing days from 1752 (?# both sets of missing days such not be in the same calendar so remove one or the other) ) (?n:^(?=\d) # the character at the beginning a the sring must be a digit ( (?<month> (0?[13578])|1[02]| #months with 31 days (0?[469]|11)(?!.31)| # months with 30 days 0?2 # February (?(.29) # if feb 29th check for valid leap year (?=.29. (?! #exclude these years from leap year pattern 000[04] #No year 0 and no leap year in year 4 | (?:(?:1[^0-6]|[2468][^048]|[3579][^26])00) (?# centurial years > 1500 not evenly divisible by 400 are not leap year) ) (?:(?:(?:\d\d) # century (?:[02468][048]|[13579][26]) #leap years (?!\x20BC))|(?:00(?:42|3[0369]|2[147]|1[258]|09)\x20BC)) )| # else if not Feb 29 (?!.3[01]) # and day not Feb 30 or 31 ) #end Leap year check ) #end of month check (?<sep>[-./]) # choose a date separator (?<day>0?[1-9]|[12]\d|3[01]) #days between 1-31 (?# The maximum number of days allowed for a month has already been checked for in the month check. If you made it this far the number of day is within the range for the given month) \k<sep> # Match the same date separator choosen before. (?!0000) # There is no year 0 (?<year>(?=(?:00(?:4[0-5]|[0-3]?\d)\x20BC)|(?:\d{4}(?:\z|(?:\x20\d))))\d{4}(?:\x20BC)? # a four digit year. Use leading zeros if needed ) (?(?=\x20\d)\x20|$))? # if there is a space followed by a digit check for time (?<time> ( # 12 hour format (0?[1-9]|1[012]) # hours (:[0-5]\d){0,2} # optional minutes and seconds (?i:\x20[AP]M) # required AM or PM )| # 24 hour format ( [01]\d|2[0-3]) #hours (:[0-5]\d){1,2}) #required minutes optional seconds ?$)
Description
Datetime for Julian and Gregorian Calenders Matchs dates from 0001 A.D. to 9999 A.D. Days and months are 1 or 2 digits Years are 4 digit with leading zeros if required. February is validate in all leap years Leap year rules for Julian and Gregorian calendars (http://scienceworld.wolfram.com/astronomy/LeapYear.html) Missing days for 1582 and 1752 are not matched. Though only one set should be applied to a calendar since they are caused by when the calendar was adopted Missing days (http://scienceworld.wolfram.com/astronomy/GregorianCalendar.html) Time can be either 12 or 24 hour format 12 hour format hh:MM:ss AM|PM minutes and seconds are optional 24 hour format hh:mm:ss seconds are optional, hours less than ten require leading zero Datetome format is a date, a space then a time.
Matches
12/25/0004 | 12/31/0001 BC 2:15 AM | 2-29-2004 09:00
Non-Matches
00/00/0000 | 2-29-2100 | 10/8/1582
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
\p{IsBasicLatin}
Description
Matches any character is the Basic Latin Unicode Range \U0000-U007F (Ascii 0-127) I've blogged about this and other expressions here http://blogs.regexadvice.com/mash/archive/2004/04/17/988.aspx
Matches
ABCxyz | 123 | +-=
Non-Matches
? | ? | ?
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
\p{N}
Description
Matches numbers. Note: the second match (?) and the second non-match (IV) are not the same. I cover this in more detail here http://blogs.regexadvice.com/mash/archive/2004/04/17/988.aspx
Matches
123890 | ? | &#189;
Non-Matches
AAABB | IV | Ten
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
\p{Sm}
Description
Math Symbols. NOTE: the second examples of match and non-match are not the same. The non-match is the keyboard dash. The match is the unicode minus sign.
Matches
+= | - | &#177; v =
Non-Matches
1 | - | 1x2
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
^(?=[^\d_].*?\d)\w(\w|[!@#$%]){7,20}
Description
This regex can be used to restrict passwords to a length of 8 to 20 aplhanumeric characters and select special characters. The password also can not start with a digit, underscore or special character and must contain at least one digit.
Matches
password1 | pa$$word2 | pa!@#$%3
Non-Matches
password | 1stpassword | $password#
Author Rating: The rating for this expression. Michael Ash
Title Test Details yyyy/mm/dd hhMMss Date
Expression
^(?ni:(?=\d)((?'year'((1[6-9])|([2-9]\d))\d\d)(?'sep'[/.-])(?'month'0?[1-9]|1[012])\2(?'day'((?<!(\2((0?[2469])|11)\2))31)|(?<!\2(0?2)\2)(29|30)|((?<=((1[6-9]|[2-9]\d)(0[48]|[2468][048]|[13579][26])|(16|[2468][048]|[3579][26])00)\2\3\2)29)|((0?[1-9])|(1\d)|(2[0-8])))(?:(?=\x20\d)\x20|$))?((?<time>((0?[1-9]|1[012])(:[0-5]\d){0,2}(\x20[AP]M))|([01]\d|2[0-3])(:[0-5]\d){1,2}))?)$
Description
YYYY/MM/DD hh:mm:ss format DateTime Regex. This regex will validate a date, time or a datetime. It will also capture the date fields and the time. Dates are in the YYYY/MM/DD format and validated for months, number of days in a month and leap years (29/2) Date field can be separated by matched periods(.), dashes(-) or forward slashes(/) Time is either 12 hour AM/PM format (hh:mm:ss AM), where minutes and seconds are optional. AM or PM required. or 24 hour military format (hh:mm:ss), from 00:00:00 to 23:59:59, where hours and minutes fields are required, including leading 0 for hours less than 10. Please refer to http://blogs.regexadvice.com/mash/archive/2004/04/23/1021.aspx for additional info Datetime is the above date and time formats separated by a space, with the date first (YYYY/MM/DD hh:mm:ss) !IMPORTANT NOTE: your regex engine must support lookbehinds and named groups to use this expression
Matches
12:30 PM | 2004-02-29 | 2004/3/31 02:31:35 AM
Non-Matches
2:00 | 2200.2.29 | 0000/00/00 00:00:00 AM
Author Rating: The rating for this expression. Michael Ash
Title Test Details Pattern Title
Expression
(?i:([A-D])(?!\1)([A-D])(?!\1|\2)([A-D])(?!\1|\2|\3)([A-D]))
Description
This regex validates a string of non-repeating characters A, B, C, D.
Matches
abcd | dbca | badc
Non-Matches
abba | baaa | cabb
Author Rating: Not yet rated. Michael Ash
Title Test Details Social Security Number
Expression
^(?!000)([0-6]\d{2}|7([0-6]\d|7[012]))([ -]?)(?!00)\d\d\3(?!0000)\d{4}$
Description
This regex validates U.S. social security numbers, within the range of numbers that have been currently allocated.
Matches
078-05-1120 | 078 05 1120 | 078051120
Non-Matches
987-65-4320 | 000-00-0000 | (555) 555-5555
Author Rating: The rating for this expression. Michael Ash
Title Test Details HTML 4.01 Elements
Expression
(<\/?)(?i:(?<element>a(bbr|cronym|ddress|pplet|rea)?|b(ase(font)?|do|ig|lockquote|ody|r|utton)?|c(aption|enter|ite|(o(de|l(group)?)))|d(d|el|fn|i(r|v)|l|t)|em|f(ieldset|o(nt|rm)|rame(set)?)|h([1-6]|ead|r|tml)|i(frame|mg|n(put|s)|sindex)?|kbd|l(abel|egend|i(nk)?)|m(ap|e(nu|ta))|no(frames|script)|o(bject|l|pt(group|ion))|p(aram|re)?|q|s(amp|cript|elect|mall|pan|t(r(ike|ong)|yle)|u(b|p))|t(able|body|d|extarea|foot|h|itle|r|t)|u(l)?|var))(\s(?<attr>.+?))*>
Description
This RE will match all the valid elements in HTML 4.01
Matches
<HTML> | <a href="link.html">Link</a>
Non-Matches
<xml> | <phonytag> | <image>
Author Rating: The rating for this expression. Michael Ash
Title Test Details (X)HTML click events
Expression
(?i:on(blur|c(hange|lick)|dblclick|focus|keypress|(key|mouse)(down|up)|(un)?load|mouse(move|o(ut|ver))|reset|s(elect|ubmit)))
Description
This regex will match all the valid on event attributes in HTML 4.01/XHTML 1.0
Matches
onclick | onsubmit | onmouseover
Non-Matches
click | onandon | mickeymouse
Author Rating: The rating for this expression. Michael Ash
Title Test Details MM/dd/yyyy HH:mm:ss.fff Datetime \w milliseconds
Expression
(?n:^(?=\d)((?<month>(0?[13578])|1[02]|(0?[469]|11)(?!.31)|0?2(?(.29)(?=.29.((1[6-9]|[2-9]\d)(0[48]|[2468][048]|[13579][26])|(16|[2468][048]|[3579][26])00))|(?!.3[01])))(?<sep>[-./])(?<day>0?[1-9]|[12]\d|3[01])\k<sep>(?<year>(1[6-9]|[2-9]\d)\d{2})\x20)(?<time>(?<hours>[01]\d|2[0-3]):(?<minutes>[0-5]\d):(?<seconds>[0-5]\d)\.(?<milliseconds>\d{3}))$)
Description
Date-time with milliseconds. MM/dd/yyyy HH:mm:ss.fff Time is in military format and requires leading zeroes for single digit hours and seconds and two digit milliseconds. All fields are required. This was a special request modification of another regex.
Matches
05/4/2005 12:34:53.102 | 12/31/2096 23:59:59.999
Non-Matches
05/4/2005 | 12:34:53.102
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
^((?:[a-zA-Z]:)|(?:\\{2}\w[-\w]*)\$?)\\(?!\.)((?:(?![\\/:*?<>"|])(?![.\x20](?:\\|$))[\x20-\x7E])+\\(?!\.))*((?:(?:(?![\\/:*?<>"|])(?![ .]$)[\x20-\x7E])+)\.((?:(?![\\/:*?<>"|])(?![ .]$)[\x20-\x7E]){2,15}))?$
Description
Matches drives, folders and file on a Windows OS. Folder matches must end with \ Folder and file names can not end with a space. I limited the file extension length to 15 though that not a restriction of a file's extension This is a mod of Darren's regex http://www.regexlib.com/REDetails.aspx?regexp_id=357 and my own http://www.regexlib.com/REDetails.aspx?regexp_id=137 Updated Feb 2005
Matches
C:\ | \\Server\share\path\File.txt | E:\My Files\Are\#1\
Non-Matches
C: | C:\\\ | C:\Trailing Space \
Author Rating: Not yet rated. Michael Ash
Title Test Details A.D. Calendar dates
Expression
(?#Calandar from January 1st 1 A.D to December 31, 9999 )(?# in yyyy-mm-dd format )(?!(?:1582\D10\D(?:0?[5-9]|1[0-4]))|(?#Missing days from 1582 )(?:1752\D0?9\D(?:0?[3-9]|1[0-3]))(?#or Missing days from 1752 )(?# both sets of missing days should not be in the same calendar so remove one or the other))(?n:^(?=\d)(?# the character at the beginning a the string must be a digit )((?'year'\d{4})(?'sep'[-./])(?'month'0?[1-9]|1[012])\k'sep'(?'day'(?<!(?:0?[469]|11).)31|(?<!0?2.)30|2[0-8]|1\d|0?[1-9]|(?# if feb 29th check for valid leap year )(?:(?<=(?!(?#exclude these years from leap year pattern ) 000[04](?#No year 0 and no leap year in year 4 )|(?:(?:1[^0-6]|[2468][^048]|[3579][^26])00)(?# centurial years > 1500 not evenly divisible by 400 are not leap year))(?:(?:\d\d)(?# century)(?:[02468][048]|[13579][26])(?#leap years))\k'sep'(?:0?2)\k'sep')|(?# else if not Feb 29 )(?<!\k'sep'(?:0?2)\k'sep')(?# and day not Feb 30 or 31 ))29)(?(?=\x20\d)\x20|$))?(?# if there is a space followed by a digit check for time )(?<time>((?# 12 hour format )(0?[1-9]|1[012])(?# hours )(:[0-5]\d){0,2}(?# optional minutes and seconds )(?i:\x20[AP]M)(?# required AM or PM ))|(?# 24 hour format )([01]\d|2[0-3])(?#hours )(:[0-5]\d){1,2})(?#required minutes optional seconds )?$)
Description
yyyy-mm-dd Datetime for AD, with leap year. See http://blogs.regexadvice.com/mash/archive/2004/04/23/1021.aspx for details on similar regexs
Matches
0001-06-16 12:00:01 AM | 2004/2/29 | 3:30 PM
Non-Matches
9999/99/99 | 24:00:00 | 2003-02-29
Author Rating: The rating for this expression. Michael Ash
Title Test Details Pattern Title
Expression
(?=\d)^(?:(?!(?:10\D(?:0?[5-9]|1[0-4])\D(?:1582))|(?:0?9\D(?:0?[3-9]|1[0-3])\D(?:1752)))((?:0?[13578]|1[02])|(?:0?[469]|11)(?!\/31)(?!-31)(?!\.31)|(?:0?2(?=.?(?:(?:29.(?!000[04]|(?:(?:1[^0-6]|[2468][^048]|[3579][^26])00))(?:(?:(?:\d\d)(?:[02468][048]|[13579][26])(?!\x20BC))|(?:00(?:42|3[0369]|2[147]|1[258]|09)\x20BC))))))|(?:0?2(?=.(?:(?:\d\D)|(?:[01]\d)|(?:2[0-8])))))([-.\/])(0?[1-9]|[12]\d|3[01])\2(?!0000)((?=(?:00(?:4[0-5]|[0-3]?\d)\x20BC)|(?:\d{4}(?!\x20BC)))\d{4}(?:\x20BC)?)(?:$|(?=\x20\d)\x20))?((?:(?:0?[1-9]|1[012])(?::[0-5]\d){0,2}(?:\x20[aApP][mM]))|(?:[01]\d|2[0-3])(?::[0-5]\d){1,2})?$
Description
mm/dd/yyyy hh:MM:ss Datetime for all AD years, including leap years. Javascript safe version of http://regexlib.com/REDetails.aspx?regexp_id=644. Please see that regex for details of what is being checked
Matches
11/24/0004 11:59 PM | 2.29.2008 | 02:50:10
Non-Matches
12/33/1020 | 2/29/2005 | 13:00 AM
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
^(?=\d)(?:(?!(?:(?:0?[5-9]|1[0-4])(?:\.|-|\/)10(?:\.|-|\/)(?:1582))|(?:(?:0?[3-9]|1[0-3])(?:\.|-|\/)0?9(?:\.|-|\/)(?:1752)))(31(?!(?:\.|-|\/)(?:0?[2469]|11))|30(?!(?:\.|-|\/)0?2)|(?:29(?:(?!(?:\.|-|\/)0?2(?:\.|-|\/))|(?=\D0?2\D(?:(?!000[04]|(?:(?:1[^0-6]|[2468][^048]|[3579][^26])00))(?:(?:(?:\d\d)(?:[02468][048]|[13579][26])(?!\x20BC))|(?:00(?:42|3[0369]|2[147]|1[258]|09)\x20BC))))))|2[0-8]|1\d|0?[1-9])([-.\/])(1[012]|(?:0?[1-9]))\2((?=(?:00(?:4[0-5]|[0-3]?\d)\x20BC)|(?:\d{4}(?:$|(?=\x20\d)\x20)))\d{4}(?:\x20BC)?)(?:$|(?=\x20\d)\x20))?((?:(?:0?[1-9]|1[012])(?::[0-5]\d){0,2}(?:\x20[aApP][mM]))|(?:[01]\d|2[0-3])(?::[0-5]\d){1,2})?$
Description
dd/mm/yyyy hh:MM:ss Datetime for all AD years, including leap years. Javascript safe version of http://regexlib.com/REDetails.aspx?regexp_id=691. Please see that regex for details of what is being checked
Matches
31.12.6008 | 5:30 AM | 30-04-1066
Non-Matches
00/00/0000 | 99:99:99 | 29/02/2005
Author Rating: The rating for this expression. Michael Ash
Title Test Details Pattern Title
Expression
^(?=\d)(?:(?!(?:1582(?:\.|-|\/)10(?:\.|-|\/)(?:0?[5-9]|1[0-4]))|(?:1752(?:\.|-|\/)0?9(?:\.|-|\/)(?:0?[3-9]|1[0-3])))(?=(?:(?!000[04]|(?:(?:1[^0-6]|[2468][^048]|[3579][^26])00))(?:(?:\d\d)(?:[02468][048]|[13579][26]))\D0?2\D29)|(?:\d{4}\D(?!(?:0?[2469]|11)\D31)(?!0?2(?:\.|-|\/)(?:29|30))))(\d{4})([-\/.])(0?\d|1[012])\2((?!00)[012]?\d|3[01])(?:$|(?=\x20\d)\x20))?((?:(?:0?[1-9]|1[012])(?::[0-5]\d){0,2}(?:\x20[aApP][mM]))|(?:[01]\d|2[0-3])(?::[0-5]\d){1,2})?$
Description
yyyy/mm/dd hh:MM:ss Datetime for all AD years, including leap years. Javascript safe version of http://regexlib.com/REDetails.aspx?regexp_id=760. Please see that regex for details of what is being checked
Matches
0008-02-29 | 2:34:59 PM | 9999/12/31 11:59 PM
Non-Matches
04/04/04 | 1:00 | 1999/1/32
Author Rating: The rating for this expression. Michael Ash
Title Test Details Pattern Title
Expression
^(?!\u00a2) #Don't allow cent symbol \p{Sc}? #optional unicode currency symbols (?!0,?\d) #don't allow leading zero if 1 or more unit (?:\d{1,3} # 1 to 3 digits (?:([, .])\d{3})? # if there is a separator it must be followed by 3 digits (?:\1\d{3})* # if the is more than two groups the same separtor must but used, it must be followed by 3 digits |(?:\d+)) # more than 3 digit with no comma separator ((?!\1)[,.]\d{2})?$ # option cents
Description
Internationally capable currency formats. It is NOT local aware. Should be modify for local specific validations. More detail at http://blogs.regexadvice.com/mash/archive/2004/06/08/1246.aspx
Matches
$9,876,543.21 | €9 876 543,21 | €9.876.543,21
Non-Matches
9.876.543.21 | 9,876,543,21 | 9 876 543 21
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
^\d?\d'(\d|1[01])&quot;$
Description
Height notation for feet (') and inches(&quot;)
Matches
6'3&quot; | 5'11&quot; | 10'0&quot;
Non-Matches
9 Feet 2 inches | 5'12&quot; | 5'2 1/2&quot;
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
^(?n:(?!-[\d\,]*K) (?!-((\d{1,3},)*((([3-9]\d\d|2[89]\d|27[4-9])\xB0C)|(((4[6-9]|[5-9]\d)\d)\xB0F)))) -?\d{1,3}(,\d{3})*(\xB0[CF]|K) )$
Description
Temperature scale. From ABSOLUTE ZERO up. Can use the Fahrenheit, Celsius or Kelvin Scale. The Degree symbol is required for Fahrenheit and Celsius. Numbers over 1,000 must be comma delimited.
Matches
32&#176;F | -10&#176;C | 4,000K
Non-Matches
-460&#176;F | 1000&#176;C | -1&#176;K
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
([2-9JQKA]|10)([\u2660\u2663\u2665\u2666])
Description
Matches each card in the deck of standard playing cards, not including the Jokers
Matches
A?A?A?A? | 2?3?4?5? | 10?J?Q?K?
Non-Matches
1? | 11? | R?
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
(?-i:\b\p{Ll}+\b)
Description
This pattern matches lower-case letters
Matches
test | hol&#227; | p
Non-Matches
Test | 123 | ?S
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
(?-i:\b\p{Lu}+\b)
Description
Matches uppercase unicode alpha characters
Matches
ABCDE | ??G?? | Æ
Non-Matches
abc | aß?d | æ
Author Rating: Not yet rated. Michael Ash
Title Test Details dd/mm/yyyy hhMMss Julian to Gregorian DateTime
Expression
(?#Datetime for Julian and Gregorian Calenders Matchs dates from 0045 BC to 9999 A.D. Days and months are 1 or 2 digits Years are 4 digit with leading zeros if required. February is validate in all leap years Leap year rules for Julian and Gregorian calendars http://scienceworld.wolfram.com/astronomy/LeapYear.html Missing days for 1582 and 1752 are not matched. Though only one set should be applied to a calendar since they are caused by when the calendar was adopted Missing days http://scienceworld.wolfram.com/astronomy/GregorianCalendar.html Time can be either 12 or 24 hour format 12 hour format hh:MM:ss AM|PM minutes and seconds are optional 24 hour format hh:mm:ss seconds are optional, hours less than ten require leading zero Datetome format is a date, a space then a time. ) (?#Calandar from January 1st 45 B.C. to December 31, 1999 in dd/mm/yyyy format) (?! (?:(?:0?[5-9]|1[0-4])(?<sep>[-./])10\k<sep>(?:1582))| #Missing days from 1582 (?:(?:0?[3-9]|1[0-3])(?<sep>[-./])0?9\k<sep>(?:1752)) #or Missing days from 1752 (?# both sets of missing days such not be in the same calendar so remove one or the other) ) (?n:^(?=\d) # the character at the beginning a the sring must be a digit ( (?<day>31(?!.0?[2469]|11)|30(?!.0?2)| 29(?(.0?2)(?=.0?2.(?! #exclude these years from leap year pattern 000[04] #No year 0 and no leap year in year 4 | (?:(?:1[^0-6]|[2468][^048]|[3579][^26])00) (?# centurial years > 1500 not evenly divisible by 400 are not leap year) ) (?:(?:(?:\d\d) # century (?:[02468][048]|[13579][26]) #leap years (?!\x20BC))|(?:00(?:42|3[0369]|2[147]|1[258]|09)\x20BC)))|(?!.0?2))| 2[0-8]|1\d|0?[1-9]) (?<sep>[-./]) # choose a date separator (?<month> (0?[1-9])|1[012]) #end of month check (?# The maximum number of days allowed for a month has already been checked for in the month check. If you made it this far the number of day is within the range for the given month) \k<sep> # Match the same date separator choosen before. (?<year>(?=(?:00(?:4[0-5]|[0-3]?\d)\x20BC)|(?:\d{4}(?:\z|(?:\x20\d))))\d{4}(?:\x20BC)? # a four digit year. Use leading zeros if needed ) (?(?=\x20\d)\x20|$))? # if there is a space followed by a digit check for time (?<time> ( # 12 hour format (0?[1-9]|1[012]) # hours (:[0-5]\d){0,2} # optional minutes and seconds (?i:\x20[AP]M) # required AM or PM )| # 24 hour format ( [01]\d|2[0-3]) #hours (:[0-5]\d){1,2}) #required minutes optional seconds ?$)
Description
dd-mm-yyyy Datetime for AD, with leap year. See http://blogs.regexadvice.com/mash/archive/2004/04/23/1021.aspx for details on this and similar regexs
Matches
30-4-2004 | 29/2/2004 3:35 PM | 23:00:00
Non-Matches
1/31/2004 | 23:23 AM | 29/2/2005
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
\b-?[1-9](?:\.\d+)?[Ee][-+]?\d+\b
Description
Matches standard scientific notation using E character Scientific notation involves writing a number as the product of two numbers. The first one, the digit value, is always more than one and less than 10. The other, the exponential term, is expressed as a power of 10.
Matches
3.7E-11 | -2.384E-03 | 9.4608e15
Non-Matches
3.7 X 10-11 | -23.84E-02 | 9.4608 x 1015
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
(?![\uD800-\uDBFF])(?![\uDC00-\uDFFF])[\u0080-\uFFFF]
Description
Unicode Plane 0 character excluding standard ASCII
Matches
&#169; | S | ?
Non-Matches
A | ?? | 4
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
[\uD800-\uDBFF][\uDC00-\uDFFF]
Description
Non-Plane 0 Unicode character
Matches
?? | ?? | ??
Non-Matches
A | v | ?
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
(\S+)\x20{2,}(?=\S+)
Description
Trim Inside. This pattern can be used with a replace value of &quot;$1 &quot; to remove multiple consecutive spaces between characters and replace with a single space. Trailing and leading spaces are NOT altered.
Matches
Too Many spaces.
Non-Matches
No extra spaces | No Extra spaces Inside
Author Rating: Not yet rated. Michael Ash
Title Test Details Word Break
Expression
^(?:[ -~]{10,25}(?:$|(?:[\w!?.])\s))
Description
Word Break. This regex can be used to break a long line of text on a full word. The qualifiers specify the minimum and maximum number of character allow before the break and can be changed according to your need. Blogge about this here http://regexadvice.com/blogs/mash/archive/2005/02/09/324.aspx
Matches
This is just a simple sample
Non-Matches
A sample
Author Rating: Not yet rated. Michael Ash
Title Test Details Date Validator
Expression
^((31(?!(\-)((F|f)(E|e)(B|b)|(A|a)(P|p)(R|r)|(J|j)(U|u)(N|n)|(S|s)(E|e)(P|p)|(N|n)(O|o)(V|v))))|((30|29)(?!(\-)((F|f)(E|e)(B|b))))|(29(?=(\-)(F|f)(E|e)(B|b)(\-)(((1[6-9]|[2-9]\d)(0[48]|[2468][048]|[13579][26])|((16|[2468][048]|[3579][26])00)))))|(0?[1-9])|1\d|2[0-8])(\-)((J|j)(A|a)(N|n)|(F|f)(E|e)(B|b)|(M|m)(A|a)(R|r)|((M|m)(A|a)(Y|y))|(A|a)(P|p)(R|r)|(J|j)(U|u)(L|l)|(J|j)(U|u)(N|n)|(A|a)(U|u)(G|g)|(O|o)(C|c)(T|t)|(S|s)(E|e)(P|p)|(N|n)(O|o)(V|v)|(D|d)(E|e)(C|c))(\-)((1[6-9]|[2-9]\d)\d{2})$
Description
This is the date validator for dates of the format DD-MMM-YYY
Matches
25-Nov-2005, 25-dEc-2006, 18-2004
Non-Matches
19-Fab-2005, 19--dec-2006
Author Rating: The rating for this expression. Mahhek Khan
Title Test Details Dutch License Plate
Expression
^([A-Z]{2}-[A-Z]{2}-[0-9]{2}$|^([A-Z]{2}-[0-9]{2}-[A-Z]{2}$|^([0-9]{2}-[A-Z]{2}-[A-Z]{2}$|^([A-Z]{2}-[0-9]{2}-[0-9]{2}$/
Description
Test on current types of Dutch license plates
Matches
12-RT-BE, DE-07-90
Non-Matches
12-12ED
Author Rating: Not yet rated. Richard Elias
Title Test Details 1-888-411-1123 Office 365 Support USA Phone Number
Expression
Office 365 Support
Description
Office 365 offers the complete solution for a person working in an office environment. It has all the features and tools that are essential for a smooth MS Office. If you want to take instant moment support to fight from all obstacles, then you have to dial MS office 365 technical support number. Our service is available in the 24 hours time span, and you can carry on your work in the flawless manner. Our MS Office 365 Support Phone Number is always reachable to hear customer complaint in the seamless manner.
Matches
http://www.emailsuport.com/office365.html
Non-Matches
emailsuport
Author Rating: Not yet rated. joeburns
Title Test Details All existing TLDs (Top-Level Domains) according to IANA specifications
Expression
(a(?:[cdefgilmnoqrstuwxz]|ero|(?:rp|si)a)|b(?:[abdefghijmnorstvwyz]iz)|c(?:[acdfghiklmnoruvxyz]|at|o(?:m|op))|d[ejkmoz]|e(?:[ceghrstu]|du)|f[ijkmor]|g(?:[abdefghilmnpqrstuwy]|ov)|h[kmnrtu]|i(?:[delmnoqrst]|n(?:fo|t))|j(?:[emop]|obs)|k[eghimnprwyz]|l[abcikrstuvy]|m(?:[acdeghklmnopqrstuvwxyz]|il|obi|useum)|n(?:[acefgilopruz]|ame|et)|o(?:m|rg)|p(?:[aefghklmnrstwy]|ro)|qa|r[eosuw]|s[abcdeghijklmnortuvyz]|t(?:[cdfghjklmnoprtvwz]|(?:rav)?el)|u[agkmsyz]|v[aceginu]|w[fs]|y[etu]|z[amw])
Description
This regexp matches all existing TLDs (Top-Level Domains) according to IANA specifications as of 14/07/2007.
Matches
all ccTLDs (Country-Code Top-Level Domains) | all gTLDs (Generic Top-Level Domains) | .arpa
Non-Matches
n.o.n - e.x.i.s.t.i.n.g T.L.D.s
Author Rating: The rating for this expression. Daniel Beck
Title Test Details Fraction numbers
Expression
(?:-(?!0))?\d+(?:(?: \d+)?/\d+)?
Description
This regexp matches string which represents a fraction. This fraction can be in these forms:<br /> 1. # or -# (not -0)<br /> 2. #/# or -#/# (not -0/#)<br /> 3. # #/# or -# #/# (not -0 #/#)
Matches
-1, 1, -1/2, 1/2, -1 2/3, 1 2/3 | 0, 0/1, 1/0, 1 0/2, 1 2/0
Non-Matches
letters | negative zero | / | #/ | /# | # / | # #/ | # /#
Author Rating: The rating for this expression. Daniel Beck
Title Test Details Twitter Username
Expression
^([a-zA-Z0-9]{1,15})$
Description
Simple validation reg ex that requires 1-15 alphanumeric characters
Matches
kazoosoft | tw33tfan | MediaOwls
Non-Matches
@lpha | bad\username | badname1234567890
Author Rating: The rating for this expression. Joseph Cardoza
Title Test Details UK Vehicle Registration Plate / Number Plate
Expression
([A-HJ-PR-Y]{2}([0][1-9]|[1-9][0-9])|[A-HJ-PR-Y]{1}([1-9]|[1-2][0-9]|30|31|33|40|44|55|50|60|66|70|77|80|88|90|99|111|121|123|222|321|333|444|555|666|777|888|999|100|200|300|400|500|600|700|800|900))[ ][A-HJ-PR-Z]{3}$
Description
UK Vehicle Registration Plate / Number Plate format as specified by the DVLA. Accepts both "Prefix" and "New" style. Allows only valid DVLA number combinations as not all are supported. Registration number must be exactly as is displayed on car, hence all letters must be in uppercase and a space seperating the two sets of characters.
Matches
AB12 RCY | CD07 TES | S33 GTT | Y999 FVB
Non-Matches
ab12 rcy | CD07 TIS | S34 GTT | Z999 FVB
Author Rating: Not yet rated. Stephen S
Title Test Details YYYY-MM-DD HH:MM:SS
Expression
^([0-9]{4})-([0-1][0-9])-([0-3][0-9])\s([0-1][0-9]|[2][0-3]):([0-5][0-9]):([0-5][0-9])$
Description
SQL datetime format tester YYYY-MM-DD HH:MM:SS
Matches
2007-07-01 01:01:01 | 2007-08-04 18:01:01
Non-Matches
2007-07-01 | 2007/07/01 | 2007-08-04 24:00:00 | 2007/07/01 12:12
Author Rating: Not yet rated. Fehér Zsolt
Title Test Details Pattern Title
Expression
^[a-zA-Z0-9\x20'\.]{8,64}[^\s]$
Description
Bobby's Burger Barn Bills Barn O'Bass Billy Bob Beaumont
Matches
Bobby's Burger Barn | Bills Barn o Bass | Billy Bob Beaumont
Non-Matches
Billy | Billy Bob Beaumont With a space on the end
Author Rating: Not yet rated. Brian Webb
Title Test Details Validate ZA Phone Numbers
Expression
^((?:\+27|27)|0)(\d{2})-?(\d{3})-?(\d{4})$
Description
Matches South African telephone/mobile numbers, with or without the country code. Can also include spaces or hyphens between values. Doesn't match brackets around the area code, but that would be easy to add in. Hope it helps someone...
Matches
0111231234 | 011 123 1234 | 011-123-1234 | 0821231234 | +27821231234 | +2782-123-1234 | +2782 123 1234 | 27111231234 | 2711 123 1234 | 2711-123-1234
Non-Matches
(011)1231234 | (+2711) 123 1234 | (011) 123-1234
Author Rating: The rating for this expression. Rory Cottle
Title Test Details Pattern Title
Expression
^\d{3}-\d{2}-\d{4}$
Description
This regular expression will match a hyphen-separated Social Security Number (SSN) in the format NNN-NN-NNNN.
Matches
333-22-4444 | 123-45-6789
Non-Matches
123456789 | SSN
Author Rating: Not yet rated. Steven Smith
Title Test Details Remove all html tags
Expression
<!DOCTYPE[\s\S]*?</head>[\s\S]*?|<form[\s\S]*?>[\s\S]*?|<button[\s\S]*?</button>[\s\S]*?|<[a-zA-Z]+(\s+[a-zA-Z]+\s*=\s*("([^"]*)"|'([^']*)'))*\s*/>|</a>|</li>|</ol>|</div><strong>|</strong>|</dd>|</dt>|<header>|</header>|<dd|</form>|<div>|<center>|</center>|</dl>|</article>|<a>|<a name[\s\S]*?>[\s\S]*?|</aside>|</section>|</div>|</ul>|</tr>|<tr>|</span>|</td>|<td>|</nav>|</table>|<td|<dt|----|<dl|<time class[\s\S]*?>[\s\S]*?|<article[\s\S]*?>[\s\S]*?|<td[\s\S]*?</td>[\s\S]*?|<section[\s\S]*?>[\s\S]*?|<div dir[\s\S]*?>[\s\S]*?|<option[\s\S]*?option>[\s\S]*?|<body[\s\S]*?>[\s\S]*?|bgcolor[\s\S]*?>[\s\S]*?|<blackquote|</blackquote>|<small|<small>|</small>|<textarea id[\s\S]*?</html>[\s\S]*?|<td valign[\s\S]*?>[\s\S]*?|<fb[\s\S]*?>[\s\S]*?|<font [\s\S]*?>[\s\S]*?|<footer[\s\S]*?</footer>[\s\S]*?|<h2[\s\S]*?</h2>[\s\S]*?|<a onMouseOver[\s\S]*?</a>[\s\S]*?|<h3[\s\S]*?</h3>[\s\S]*?|<th[\s\S]*?</th>[\s\S]*?|<tbody>[\s\S]*?</tbody>[\s\S]*?|<div class="fb-like"[\s\S]*?>[\s\S]*?|<input[\s\S]*?>[\s\S]*?|<tfoot>[\s\S]*?</tfoot>[\s\S]*?|<script[\s\S]*?/script>[\s\S]*?|<table[\s\S]*?>[\s\S]*?|<cite[\s\S]*?</cite>[\s\S]*?|<style id[\s\S]*?</style>[\s\S]*?|<li id[\s\S]*?>[\s\S]*?|<p id=[\s\S]*?>[\s\S]*?|<ul[\s\S]*?>[\s\S]*?|<a title[\s\S]*?>[\s\S]*?|<li[\s\S]*?>[\s\S]*?|<style type[\s\S]*?/style>[\s\S]*?|<object[\s\S]*?/object>[\s\S]*?|<label[\s\S]*?/label>[\s\S]*?|<select[\s\S]*?</select>[\s\S]*?|(<a href[\s\S]*?>[\s\S]*?)|(\b(http|https):\/\/.*[^ alt]\b)|href=[\s\S]*?>[\s\S]*?|<a id[\s\S]*?>[\s\S]*?|<!--[\s\S]*?-->[\s\S]*?|<div style[\s\S]*?>[\s\S]*?|<span[\s\S]*?>[\s\S]*?|<span lang[\s\S]*?>[\s\S]*?|<img[\s\S]*?>[\s\S]*?|<div id[\s\S]*?>[\s\S]*?|<header[\s\S]*?>[\s\S]*?|<a target[\s\S]*?>[\s\S]*?|<div class[\s\S]*?>[\s\S]*?|</object>|<hr align[\s\S]*?>[\s\S]*?|<embed[\s\S]*?/>[\s\S]*?|<ol[\s\S]*?>[\s\S]*?|<a rel[\s\S]*?>[\s\S]*?|<param[\s\S]*?/>[\s\S]*?|<noscript>[\s\S]*?</noscript>[\s\S]*?|<aside id[\s\S]*?>[\s\S]*?|<xml>[\s\S]*?</xml>[\s\S]*?|<nav[\s\S]*?>[\s\S]*?|<link rel[\s\S]*?>[\s\S]*?|<p style[\s\S]*?>[\s\S]*?|<iframe[\s\S]*?</iframe>[\s\S]*?|<span rel[\s\S]*?>[\s\S]*?|<span id[\s\S]*?>[\s\S]*?|<span property=[\s\S]*?>[\s\S]*?|<span class[\s\S]*?>[\s\S]*?|<div align[\s\S]*?>[\s\S]*?|<form[\s\S]*?>[\s\S]*?|<p class[\s\S]*?>[\s\S]*?|<h3 property[\s\S]*?>[\s\S]*?|<time[\s\S]*?</time>[\s\S]*?|class=[\s\S]*?>[\s\S]*?|<video src[\s\S]*?>[\s\S]*?|<a class[\s\S]*?>[\s\S]*?|&rarr;|style=[\s\S]*?;"[\s\S]*?|<h3 id[\s\S]*?">[\s\S]*?|<center>|</center>|</dl>|<span dir="ltr">|<a name[\s\S]*?>[\s\S]*?|<a name='links'>|<abbr[\s\S]*?</abbr>[\s\S]*?|<span itemprop[\s\S]*?>[\s\S]*?|<amp-iframe[\s\S]*?</amp-iframe>[\s\S]*?|<amp-img[\s\S]*?</amp-img>[\s\S]*?|<amp-img src=">|<stylep-custom>[\s\S]*?</style>[\s\S]*?|<stylep-boilerplate>[\s\S]*?</style>[\s\S]*?|src=">|<amp[\s\S]*?pixel>[\s\S]*?|Leave a Reply|<body>|<body|<h3>|</h3>|<div class[\s\S]*?>[\s\S]*?|<aside[\s\S]*?>[\s\S]*?|<p class=[\s\S]*?>[\s\S]*?|
Description
A little long REGEX but remove almost all html tags
Matches
links, forms, scripts,
Non-Matches
text|txt|aps
Author Rating: Not yet rated. Melcu Suzana
Title Test Details Date and time (10 february 2014 at 0:10)
Expression
\d{2} \D+[a-z] \d{4} at \d{2}:\d{2}
Description
This regex will match this kind of date: 10 february 2014 at 0:10
Matches
10 february 2014 at 0:10
Non-Matches
non
Author Rating: Not yet rated. Melcu Suzana
Title Test Details http://purelifegreencoffeebeanadvice.com/clariderm-cream-reviews/
Expression
http://purelifegreencoffeebeanadvice.com/clariderm-cream-reviews/
Description
Clariderm Cream The natural ingredients in the boots Expert Sensitive Hydrating Eye Cream my partner and i find very nourishing and moisturizing are the sunflower oil, aloe, as well as vitamins minerals. You'll find some unnatural ingredients in this particular eye cream such while parabens and waxes, but that doesn't keep me from employing this cream it does an excellent job hydrating the Skin Care Review around my eyes. http://purelifegreencoffeebeanadvice.com/clariderm-cream-reviews/
Matches
http://purelifegreencoffeebeanadvice.com/clariderm-cream-reviews/
Non-Matches
http://purelifegreencoffeebeanadvice.com/clariderm-cream-reviews/
Author Rating: Not yet rated. jake elis
Title Test Details Whole Number
Expression
^[0]$|^-?[1-9]\d*$
Description
This match an whole number
Matches
0 | 100 | -100
Non-Matches
000 | -0 | +10 | a1 | 1a
Author Rating: The rating for this expression. Michael Sogos
Title Test Details German Telephone Number
Expression
[0-9.\-/+() ]{4,}
Description
This regex supports international praefix, the national (0) and extension numbers.
Matches
+49 (0)40/529 567-31; 529 567-31
Non-Matches
529
Author Rating: The rating for this expression. etdgoibjuuy
Title Test Details German Postal Code
Expression
[D]?[-D]?[0-9]{5}
Description
German postal code with or without national praefix.
Matches
D-25335; 25335
Non-Matches
5335
Author Rating: The rating for this expression. etdgoibjuuy
Title Test Details Pattern Title
Expression
^(([A-Z]{1,2}[0-9]{1,2})|([A-Z]{1,2}[0-9][A-Z]))\s?([0-9][A-Z]{2})$
Description
Matches UK postcodes of the below formats. The space is optional. AN NAA AAN NAA ANN NAA ANA NAA AANA NAA AANN NAA
Matches
A11AA | AA1A 1AA | AA11 1AA
Non-Matches
AAA 1AA | AA11A 1AA | AAA1AA
Author Rating: The rating for this expression. Phil A
Title Test Details http://www.seremolynbuy.com/hydro-muscle-max-reviews/
Expression
sadgtr
Description
Milk - This Can Be something which can also be authorized in virtually every part of competitive activities. It's will help you get muscle quickly; together with that it tastes decent and wonderful. You want to Hydro Muscle Max consider this as well since it will help you build muscle exactly the same technique protein does - you may not want to get them both. That's too much protein.The body may be the same, we must Muscle Building Supplements balance out all our four "thighs" before we can standup right. These four feet areadequate sleep, a healthy and healthy diet, a suitable workout regimen plus a great metabolism. Read more ==> http://www.seremolynbuy.com/hydro-muscle-max-reviews/
Matches
xzcgh
Non-Matches
fdhj
Author Rating: Not yet rated. markleeman
Title Test Details http://www.seremolynbuy.com/hydro-muscle-max-reviews/
Expression
sadgtr
Description
Milk - This Can Be something which can also be authorized in virtually every part of competitive activities. It's will help you get muscle quickly; together with that it tastes decent and wonderful. You want to Hydro Muscle Max consider this as well since it will help you build muscle exactly the same technique protein does - you may not want to get them both. That's too much protein.The body may be the same, we must Muscle Building Supplements balance out all our four "thighs" before we can standup right. These four feet areadequate sleep, a healthy and healthy diet, a suitable workout regimen plus a great metabolism. Read more ==> http://www.seremolynbuy.com/hydro-muscle-max-reviews/
Matches
http://www.seremolynbuy.com/hydro-muscle-max-reviews/
Non-Matches
bodybuilding
Author Rating: Not yet rated. markleeman
Title Test Details Yahoo Support Phone Number | 1-855-984-1516
Expression
Yahoo Support Phone Number
Description
Dial our Yahoo Support Phone Number 1 855 984 1516 for any technical issue related to your yahoo mail. We are offering 24x7 Yahoo Customer Support Service to our clients. To Gain our services or get in touch with our experts feel free to interact with us on 1-855-984-1516 FREE or visit our site http://www.yahootechsupport24x7.com
Matches
Yahoo Support Phone Number, Yahoo Technical Support, Yahoo Tech Support Number, Yahoo Customer Service Phone Number
Non-Matches
N/A
Author Rating: Not yet rated. Arnold James
Title Test Details French phone number
Expression
^(0|\+33)[1-9]([-. ]?[0-9]{2}){4}$
Description
Match french phone number with or without french international dialling code
Matches
+33622313131 | 02 02 02 02 02 | 0303030303
Non-Matches
+34622313131 | 1702020202
Author Rating: The rating for this expression. axi
Title Test Details Validate string prefix
Expression
^([a-zA-Z]{5})([a-zA-Z0-9-]{3,12})
Description
Validate: First five characters are letters; characters six-17 are letters, numbers, or hyphen; string length is eight characters minimum, 17 characters maximum
Matches
ABCDE123abc-123AB
Non-Matches
1BCDE123abc-123AB -BCDE123abc-123AB ABCDE6789012345678
Author Rating: The rating for this expression. greg askew
Title Test Details Pattern Title
Expression
^09(73|74|05|06|15|16|17|26|27|35|36|37|79|38|07|08|09|10|12|18|19|20|21|28|29|30|38|39|89|99|22|23|32|33)\d{3}\s?\d{4}
Description
Validates a Philippine mobile phone number without International code. Includes country's six area codes for mobile phones: Express Telecom, Globe Telecom, Next Mobile, Red Mobile, Smart Communications and Sun Cellular
Matches
09171234567 | 0905 123 4567
Non-Matches
+639111111 | 09011234567 | 0915 1234 23 2
Author Rating: The rating for this expression. Abram John A. Limpin
Title Test Details RFC Registro Federal de Contribuyentes (MEXICO)
Expression
^([A-Z|a-z|&amp;]{3})(([0-9]{2})([0][13456789]|[1][012])([0][1-9]|[12][\d]|[3][0])|([0-9]{2})([0][13578]|[1][02])([0][1-9]|[12][\d]|[3][01])|([02468][048]|[13579][26])([0][2])([0][1-9]|[12][\d])|([1-9]{2})([0][2])([0][1-9]|[12][0-8]))(\w{2}[A|a|0-9]{1})$|^([A-Z|a-z]{4})(([0-9]{2})([0][13456789]|[1][012])([0][1-9]|[12][\d]|[3][0])|([0-9]{2})([0][13578]|[1][02])([0][1-9]|[12][\d]|[3][01])|([02468][048]|[13579][26])([0][2])([0][1-9]|[12][\d])|([1-9]{2})([0][2])([0][1-9]|[12][0-8]))((\w{2})([A|a|0-9]{1})){0,3}$
Description
Registro Federal de Contribuyentes (RFC) , used in Mexico as a unique set of characters for a person or corporation registration . Registro Federal de Contribuyentes utilizado en Mexico para el registro en hacienda (includes leap years)
Matches
ABCD790419 | ABC790419aa1 |ABC800229aa1
Non-Matches
AB790419 | A12790419 | ABC791332
Author Rating: The rating for this expression. Leo Hinojosa
Title Test Details Gregorian Date with month names and leap year support
Expression
^(0[1-9]|[12][0-9]|3[01])[\s\.\-/](J(anuary|uly|an|AN)|M(arch|ar|AR|ay|AY)|A(ugust|ug|UG)|(O(ctober|ct|CT)|(D(ecember|ec|EC))))[\s\.\-/][1-9][0-9]{3}|(0[1-9]|[12][0-9]|30)[\s\.\-/](A(pril|pr|PR)|J(une|un|UN)|S(eptember|ep|EP)|N(ovember|ov|OV))[\s\.\-/][1-9][0-9]{3}|(0[1-9]|1[0-9]|2[0-8])[\s\.\-/]F(ebruary|eb|EB)[\s\.\-/][1-9][0-9]{3}|29[\s\.\-/]F(ebruary|eb|EB)[\s\.\-/]((0[48]|[2468][048]|[13579][26])00|[0-9]{2}(0[48]|[2468][048]|[13579][26]))$
Description
Verifies all valid Gregorian dates of the form DD MONTH YYYY, and short month names, taking days/month and leap years into account. Accepts space, -, . and / between paramters.
Matches
05 March 2012 | 29-Feb-2012 | 31.DEC.2011
Non-Matches
32 March 2012 | 29-Feb-2011 | 2011.DEC.31
Author Rating: Not yet rated. Paul Kochanowsky
Title Test Details number over 100,00 with comma
Expression
^([0-9]?[0-9]?[0-9]?\\.)?(\\d{3})$*(,\\d{2})
Description
Match a number over 99,99 with the comma and dot mandatory.
Matches
100,00 | 1.000,00 | 999.999,99
Non-Matches
1 | 10 | 10.00 | 10,00 | 100 | 1000 | 1.000 | 1,000.00
Author Rating: Not yet rated. Chiel de Graaf
Title Test Details Pattern Title
Expression
^(((0?[1-9]|1[012])/(0?[1-9]|1\d|2[0-8])|(0?[13456789]|1[012])/(29|30)|(0?[13578]|1[02])/31)/(19|[2-9]\d)\d{2}|0?2/29/((19|[2-9]\d)(0[48]|[2468][048]|[13579][26])|(([2468][048]|[3579][26])00)))$
Description
MM/dd/yyyy with 100% leap years. Valid since year 1900. MM and DD could have 1 or 2 digits : M/d/yyyy or MM/d/yyyy or M/dd/yyyy This was a request from a user in http://www.regexlib.com/REDetails.aspx?regexp_id=1038
Matches
01/31/1905 | 1/9/1900 | 2/29/1904
Non-Matches
31/01/2005 | 02/29/2005 | 2/29/2005
Author Rating: The rating for this expression. Dany Lauener
Title Test Details Pattern Title
Expression
^(((0[1-9]|1[012])/(0[1-9]|1\d|2[0-8])|(0[13456789]|1[012])/(29|30)|(0[13578]|1[02])/31)/[2-9]\d{3}|02/29/(([2-9]\d)(0[48]|[2468][048]|[13579][26])|(([2468][048]|[3579][26])00)))$
Description
MM/dd/yyyy with 100% leap year validation starting from year 2000. If this one doesn't fit your needs, just tell me. Sorry for starting &quot;only&quot; from year 2000, this is so simple to change this, please ask if needed. Enjoy
Matches
02/29/2000 | 02/29/2004 | 12/31/2001
Non-Matches
02/29/2100 | 02/29/2001 | 1/1/2001
Author Rating: The rating for this expression. Dany Lauener
Title Test Details Pattern Title
Expression
^(((0[1-9]|[12]\d|3[01])\/(0[13578]|1[02])\/((19|[2-9]\d)\d{2}))|((0[1-9]|[12]\d|30)\/(0[13456789]|1[012])\/((19|[2-9]\d)\d{2}))|((0[1-9]|1\d|2[0-8])\/02\/((19|[2-9]\d)\d{2}))|(29\/02\/((1[6-9]|[2-9]\d)(0[48]|[2468][048]|[13579][26])|((16|[2468][048]|[3579][26])00))))$
Description
dd/MM/yyyy with leap years 100% integrated Valid years : from 1900 to 9999. As usual, many tests have been made. This was requested by a user : http://www.regexlib.com/REDetails.aspx?regexp_id=409
Matches
29/02/2000 | 30/04/2003 | 01/01/2003
Non-Matches
29/02/2001 | 30-04-2003 | 1/1/1899
Author Rating: The rating for this expression. Dany Lauener
Title Test Details Pattern Title
Expression
^([2-9]\d{3}((0[1-9]|1[012])(0[1-9]|1\d|2[0-8])|(0[13456789]|1[012])(29|30)|(0[13578]|1[02])31)|(([2-9]\d)(0[48]|[2468][048]|[13579][26])|(([2468][048]|[3579][26])00))0229)$
Description
yyyyMMdd with leap year validation, starting from year 2000 only. The length of the expression is minimized, but still validates all entries. If you want it with years like 1600 or separators, just ask :)
Matches
20000101 | 20051231 | 20040229
Non-Matches
19990101 | 20053112 | 20050229
Author Rating: The rating for this expression. Dany Lauener
Title Test Details Pattern Title
Expression
^(\d{2}((0[1-9]|1[012])(0[1-9]|1\d|2[0-8])|(0[13456789]|1[012])(29|30)|(0[13578]|1[02])31)|([02468][048]|[13579][26])0229)$
Description
yyMMdd with leap years. Minimized expression. As we have only 2 numbers for the years, dates 1600, 2000, etc are still validated.
Matches
001231 | 000229 | 040229
Non-Matches
003112 | 000431 | 010229
Author Rating: The rating for this expression. Dany Lauener
Title Test Details Pattern Title
Expression
^([01]\d|2[0123])([0-5]\d){2}$
Description
HHmmss without any separators. Hours in 24h format.
Matches
235959 | 000000 | 012345
Non-Matches
240000 | 23:59:59 | 236060
Author Rating: The rating for this expression. Dany Lauener
Title Test Details Pattern Title
Expression
^((((0?[1-9]|[12]\d|3[01])[\.\-\/](0?[13578]|1[02])[\.\-\/]((1[6-9]|[2-9]\d)?\d{2}))|((0?[1-9]|[12]\d|30)[\.\-\/](0?[13456789]|1[012])[\.\-\/]((1[6-9]|[2-9]\d)?\d{2}))|((0?[1-9]|1\d|2[0-8])[\.\-\/]0?2[\.\-\/]((1[6-9]|[2-9]\d)?\d{2}))|(29[\.\-\/]0?2[\.\-\/]((1[6-9]|[2-9]\d)?(0[48]|[2468][048]|[13579][26])|((16|[2468][048]|[3579][26])00)|00)))|(((0[1-9]|[12]\d|3[01])(0[13578]|1[02])((1[6-9]|[2-9]\d)?\d{2}))|((0[1-9]|[12]\d|30)(0[13456789]|1[012])((1[6-9]|[2-9]\d)?\d{2}))|((0[1-9]|1\d|2[0-8])02((1[6-9]|[2-9]\d)?\d{2}))|(2902((1[6-9]|[2-9]\d)?(0[48]|[2468][048]|[13579][26])|((16|[2468][048]|[3579][26])00)|00))))$
Description
Date with leap years. Accepts '.' '-' and '/' as separators d.m.yy to dd.mm.yyyy (or d.mm.yy, etc) Ex: dd-mm-yyyy d.mm/yy dd/m.yyyy etc etc Accept 00 years also.
Matches
29.2.2004 | 31121975 | 29/2-00
Non-Matches
29.2.2005 | 32121975 | 29.2/01
Author Rating: The rating for this expression. Dany Lauener
Title Test Details Pattern Title
Expression
^((\d{2}((0[13578]|1[02])(0[1-9]|[12]\d|3[01])|(0[13456789]|1[012])(0[1-9]|[12]\d|30)|02(0[1-9]|1\d|2[0-8])))|([02468][048]|[13579][26])0229)$
Description
Date expression validator with format YYMMDD Validates leap years. Of course, as year has only 2 digits, it's not possible to invalidate years like 2100, 2200, 2300, etc as a non-leap years !
Matches
751231 | 000229 | 040229
Non-Matches
750431 | 010229 | 050229
Author Rating: The rating for this expression. Dany Lauener
Title Test Details Pattern Title
Expression
^(((0?[1-9]|[12]\d|3[01])[\.\-\/](0?[13578]|1[02])[\.\-\/]((1[6-9]|[2-9]\d)?\d{2}))|((0?[1-9]|[12]\d|30)[\.\-\/](0?[13456789]|1[012])[\.\-\/]((1[6-9]|[2-9]\d)?\d{2}))|((0?[1-9]|1\d|2[0-8])[\.\-\/]0?2[\.\-\/]((1[6-9]|[2-9]\d)?\d{2}))|(29[\.\-\/]0?2[\.\-\/]((1[6-9]|[2-9]\d)?(0[48]|[2468][048]|[13579][26])|((16|[2468][048]|[3579][26])00)|00)))$
Description
DD.MM.YY or DD.MM.YYYY separator could be on choice '.' '/' or '-' leap years compatible, 00 is treated as year 2000.
Matches
29.2.04 | 29/02-2004 | 3.4.05
Non-Matches
29.2.03 | 2902.2004 | 12.31.1975
Author Rating: The rating for this expression. Dany Lauener
Title Test Details Pattern Title
Expression
^(((0?[1-9]|[12]\d|3[01])[\.\-\/](0?[13578]|1[02])[\.\-\/]((1[6-9]|[2-9]\d)?\d{2}|\d))|((0?[1-9]|[12]\d|30)[\.\-\/](0?[13456789]|1[012])[\.\-\/]((1[6-9]|[2-9]\d)?\d{2}|\d))|((0?[1-9]|1\d|2[0-8])[\.\-\/]0?2[\.\-\/]((1[6-9]|[2-9]\d)?\d{2}|\d))|(29[\.\-\/]0?2[\.\-\/]((1[6-9]|[2-9]\d)?(0[48]|[2468][048]|[13579][26])|((16|[2468][048]|[3579][26])00)|00|[048])))$
Description
This regexp has been posted specialy for &quot;Mike O Shea&quot; as he requested a mono digit year validation. matches DD/MM/Y or DD/MM/YYYY or D/M/Y or DD/M/YYYY Leap years treated. (Italian style with tomato) Years 0-9 equal years 2000 to 2009 for leap years
Matches
1/1/2005 | 29/02/12 | 29/02/2400
Non-Matches
29/2/2005 | 29/02/13 | 29/02/2200
Author Rating: The rating for this expression. Dany Lauener
Title Test Details Pattern Title
Expression
^(((0[1-9]|[12]\d|3[01])\/(0[13578]|1[02])\/(\d{2}))|((0[1-9]|[12]\d|30)\/(0[13456789]|1[012])\/(\d{2}))|((0[1-9]|1\d|2[0-8])\/02\/(\d{2}))|(29\/02\/((0[48]|[2468][048]|[13579][26])|(00))))$
Description
Matching : dd/MM/yy Leap years compatible Italian style, just for more fun. Please, don't forget to rate it if you use it. THX
Matches
31/12/75 | 29/02/00 | 29/02/04
Non-Matches
01/13/01 | 29/02/01 | 29/02/2004
Author Rating: Not yet rated. Dany Lauener
Title Test Details Pattern Title
Expression
^(((0[1-9]|[12]\d|3[01])\/(0[13578]|1[02])\/((1[6-9]|[2-9]\d)\d{2}))|((0[1-9]|[12]\d|30)\/(0[13456789]|1[012])\/((1[6-9]|[2-9]\d)\d{2}))|((0[1-9]|1\d|2[0-8])\/02\/((1[6-9]|[2-9]\d)\d{2}))|(29\/02\/((1[6-9]|[2-9]\d)(0[48]|[2468][048]|[13579][26])|((16|[2468][048]|[3579][26])00))))$
Description
dd/MM/yyyy with leap years 100% integrated Valid years : from 1600 to 9999 As usual, many tests have been made. I think this one should be fine.
Matches
29/02/2000 | 30/04/2003 | 01/01/2003
Non-Matches
29/02/2001 | 30-04-2003 | 1/1/2003
Author Rating: The rating for this expression. Dany Lauener
Title Test Details validate arabic letters
Expression
^[\u0621-\u064A]+$
Description
Matches strings that only contain Arabic letters (no spaces). if you want to include spaces it should be ^[\u0621-\u064A\040]+$
Matches
الله أكبر
Non-Matches
test
Author Rating: Not yet rated. Walid El-Sewaify
Title Test Details Address in minor to major order
Expression
((?<strPOBox>((POBox|PO\sBox)\s*\d*)),?\s?)?(((?<strUnit>([\w\d\s\,]*)),\s?)?( (?<strStreet>([\w\s\-]*\w\s(st\s)?[\w]*\s(street|st|road|rd|close|cl|avenue|ave|av|path|ph|drive|drv|LOOP|COURT|CT|CIRCLE|LANE|LN)) ),?\s?))?((?<strTown>([\p{Ll}\p{Lu}\p{Lo}\p{Pc}\p{Lt}\p{Lm}\s]*)),?\s?)?((?<strState>(Victoria|VIC|New South Wales|NSW|South Australia|SA|Northern Territory|NT|West Australia|WA|Tasmania|TAS|ACT|Queensland|QLD))\s*)?(?<strPostalCode>(\d{4}),?\s?)?(?<strCountry>(Australia))?
Description
This regular expression using named groups returns semantic tokens and is designed for Australian addresses in one line. Any part of an address may be omitted, as long as parts are in minor to major order. It should not be difficult to modify the regular express for analysing multi-line addresses. With a little modification, this regex may work for other postal address formats in minor to major order. The syntax is based on dot Net regular expression, with "options = RegexOptions.IgnoreCase | RegexOptions.Multiline | RegexOptions.IgnorePatternWhitespace". The order is [POBox][ExtAdr][Street][Town][State][PostalCode][Country].
Matches
Shop S1, Sussex Centre, 401 Sussex St, Sydney | 28 Lidco Street, Arndell Park, Sydney 2148 | Level 1, 198 Elizabeth St, Surry Hills 2010 | Room 2, Level 1, 198 Elizabeth St, Surry Hills, NSW 2010 | 541 Pittwater Rd, Brookvale 2100 | 2 Maniangi Court, Macedon, 3440 | PO Box 1531, Keveland, QLD 4163 | St Lucia Golf Links, 22 St George St, St Lucia, QLD | PO Box 1531, St Lucia, QLD 4163
Non-Matches
No man land
Author Rating: Not yet rated. Zijian
Title Test Details Extract YouTube ID
Expression
(?:[Yy][Oo][Uu][Tt][Uu][Bb][Ee]\.[Cc][Oo][Mm]/watch\?v=)([\w-]{11})
Description
.NET 3.5 Tested. Used to extract the YouTubeID from a fully qualified YouTube URL. Dim _Regex As New Regex("(?:[Yy][Oo][Uu][Tt][Uu][Bb][Ee]\.[Cc][Oo][Mm]/watch\?v=)([\w-]{11})", RegexOptions.IgnoreCase Or RegexOptions.Compiled) Dim _RegexMatch As Match = _Regex.Match("http://www.youtube.com/watch?v=pW2GSdxxwDg") Dim _YouTubeVideoID As System.String = _RegexMatch.Groups(1).Value
Matches
http://www.youtube.com/watch?v=pW2GSdxxwDg | http://www.youtube.com/watch?v=-7P7_kxZQ5I | http://www.youtube.com/watch?v=7sPKHwsupmQ&playnext=1&list=PL40CB7986D1A9A285 | http://www.youtube.com/watch?v=r-di4gJvq4Q&feature=channel_video_title
Non-Matches
http://www.youtu.be/watch?v=pW2GSdxxwDg
Author Rating: Not yet rated. Charlie Seitz
Title Test Details SQL constant string
Expression
'('{2})*([^'\r\n]*)('{2})*([^'\r\n]*)('{2})*'
Description
Mach with constant string in SQL style.
Matches
'''abc' | 'abc' | 'a''bc' | 'abc''' | ''''
Non-Matches
abc | 'abc | '''ab
Author Rating: The rating for this expression. Fabio Maulo
Title Test Details New Zealand phone numbers
Expression
(^\([0]\d{1}\))(\d{7}$)|(^\([0][2]\d{1}\))(\d{6,8}$)|([0][8][0][0])([\s])(\d{5,8}$)
Description
Matches New Zealand local, mobile and freecall (0800) phone numbers.
Matches
(09)1234567 | (021)123456 | (021)1234567 | (027)123456 | 0800 12345 | 0800 123457
Non-Matches
(09)123456 | (021)12345 | (031)1234567 | (027)12345 | 0800-12345 | 0800123457
Author Rating: The rating for this expression. CGRdevelopment
Title Test Details CEP Brazil
Expression
^\d{5}(\-)(\d{3})?$
Description
CEP do Brasil com separação ex: 99999-999
Matches
99999-999
Non-Matches
999999-99
Author Rating: The rating for this expression. Valter Henrique Junior
Title Test Details Numeric Range
Expression
^[0-9]%?$|^1[0-9]%?$|^2[0-9]%?$|^3[0-5]%?$|^[0-9]\.\d{1,2}%?$|^1[0-9]\.\d{1,2}%?$|^2[0-9]\.\d{1,2}%?$|^3[0-4]\.\d{1,2}%?$|^35%?$
Description
A range of numbers 0-35 optionally including a percent sign and 2 position decimal.
Matches
32.34%, 32.34, 32, 32%
Non-Matches
32.345%, 36, .34
Author Rating: The rating for this expression. Tadd Stuart
Title Test Details Easy way to cure Erectile Dysfunction
Expression
Generic Viagra Online
Description
As we master of ED so we are talking about Generic Viagra which people buy first for impotence or to have healthy sensual relation with the partner Generic Viagra Online http://www.generic-viagrarx.com/ gives you smart service and hard erection to attract your for amazing sensual what all they need is satisfaction and long time till they and Generic Viagra helps you to stand till end as a only hero for women keep trying and do your best.
Matches
Erectile Dysfunction
Non-Matches
women
Author Rating: Not yet rated. Addam Abraham
Title Test Details Date
Expression
^(([0]?[1-9])|(1[0-2]))\/(([0]?[1-9])|([1,2]\d{1})|([3][0,1]))\/[12]\d{3}$
Description
This regular expression matches the format MM/DD/YYYY. Month and Day can have an optional leading 0. Months are from 01-12, days are from 01-31, and years are from 1000-2999.
Matches
1/1/1999 | 01/01/2001 | 12/31/1900
Non-Matches
00/12/0999 | 13/1/2000 | 10/0/2009
Author Rating: The rating for this expression. Chris McCall
Title Test Details http://x4up.org/tst-1700/
Expression
TST 1700
Description
During the Body Power Expo in Birmingham I spoke with one of the judges of the competitions that were held there. I asked him about the increased transparency of adjudication. He indicated herein had been positive developments and that they were also needed. In passing, he called the battle between Sergio and Arnold in 1970, clearly indicating that he had seen happily go towards Sergio profits. To this day, I often hear people refer to this game as a wrongly assigned to Arnold profit. Sergio is the only one who ever won by Arnold. http://x4up.org/tst-1700/
Matches
fdgfdg
Non-Matches
fdg
Author Rating: Not yet rated. shirley maclaine
Title Test Details Check Iranian's Mobile Numbers
Expression
(^(09|9)[1][1-9]\\d{7}$)|(^(09|9)[3][12456]\\d{7}$)
Description
This Regular Expression Chack Matching Persian Mobile Numbers It is Checking MCI,MTN Irancell and Talya Operators For Example In C#.NET: Regex.IsMatch(MobileNumber, "(^(09|9)[1][1-9]\\d{7}$)|(^(09|9)[3][12456]\\d{7}$)");
Matches
09122838473 | 9122838473 | 09369048504
Non-Matches
+989122838473 | 22248016 | 12345
Author Rating: Not yet rated. Ali Delshad
Title Test Details Get Plain Text From Html (Remove Html Tags)
Expression
<[^>]*>
Description
This Regex Will Remove All Html Tags And Return Simple Plain Text . For Example In C#.NET : Regex.Replace(Html, "<[^>]*>", string.Empty);
Matches
<p> Hello Ali Delshad </p>
Non-Matches
Hello Ali Delshad
Author Rating: The rating for this expression. Ali Delshad
Title Test Details Check Farsi Unicode Character
Expression
[\u0600-\u06FF]
Description
This Regex chceck an input string for persian unicode character Note that it not work in javascript For Example In C#.NET: Regex.IsMatch(Text, "[\u0600-\u06FF]");
Matches
سلام | hello علی | Hi 2 سلام
Non-Matches
Hello | Ali | 123
Author Rating: The rating for this expression. Ali Delshad
Title Test Details Intuit QuickBooks Accounting Software Helpline Number Dial +1888- 411-1123
Expression
QuickBooks Helpline Phone Number
Description
You can call our Intuit QuickBooks Accounting Software Helpline team on our Toll-free number 1-877-227-2303. We provide the best Quickbooks Support available in the market. Visit - http://www.customer-servicenumber.com/quickbooks-support/
Matches
Intuit QuickBooks Accounting Software Helpline Number
Non-Matches
QB Support
Author Rating: Not yet rated. Matt Cutts
Change page:   |    Displaying page 27 of 40 pages; Items 2601 to 2700

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