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

Please support RegExLib Sponsors

Sponsors

Browse Expressions by Category

91 regular expressions found in this category!

Expressions in category: Strings

Change page:   |    Displaying page 3 of 5 pages; Items 41 to 60
Title Test Details Pattern Title
Expression
.*\$AVE|\$ave.*
Description
Spam Stopper
Matches
$ave
Non-Matches
save
Author Rating: Not yet rated. Alanski Perryman
Title Test Details Pattern Title
Expression
.*[Oo0][Ee][Mm].*
Description
Spam Stopper
Matches
OEM | 0em
Non-Matches
na
Author Rating: Not yet rated. Alanski Perryman
Title Test Details Pattern Title
Expression
.*[Vv][Ii1]agr.*
Description
Spam Stopper
Matches
V1agra
Non-Matches
na
Author Rating: Not yet rated. Alanski Perryman
Title Test Details Pattern Title
Expression
.*[Pp]re[Ss\$]cr[iI1]pt.*
Description
Spam Stopper
Matches
Pre$criptions
Non-Matches
na
Author Rating: Not yet rated. Alanski Perryman
Title Test Details Pattern Title
Expression
^(?:(?<Visa>4\d{3})|(?<Mastercard>5[1-5]\d{2})|(?<Discover>6011)|(?<DinersClub>(?:3[68]\d{2})|(?:30[0-5]\d))|(?<AmericanExpress>3[47]\d{2}))([ -]?)(?(DinersClub)(?:\d{6}\1\d{4})|(?(AmericanExpress)(?:\d{6}\1\d{5})|(?:\d{4}\1\d{4}\1\d{4})))$
Description
Updated on 7 Jun 2005 -- Matches major credit cards including: Visa (length 16, prefix 4); Mastercard (length 16, prefix 51-55); Diners Club/Carte Blanche (length 14, prefix 36, 38, or 300-305); Discover (length 16, prefix 6011); American Express (length 15, prefix 34 or 37). Saves the card type as a named group to facilitate further validation against a &quot;card type&quot; checkbox in a program. All 16 digit formats are grouped 4-4-4-4 with an optional hyphen or space between each group of 4 digits. The American Express format is grouped 4-6-5 with an optional hyphen or space between each group of digits. Formatting characters must be consistant, i.e. if two groups are separated by a hyphen, all groups must be separated by a hyphen for a match to occur.
Matches
4111-2222-3333-4444 | 3411 222222 33333 | 5111222233334444
Non-Matches
4111-2222-3333-444 | 3411-2222-3333-4444 | Visa
Author Rating: Not yet rated. Jerry Schmersahl
Title Test Details Pattern Title
Expression
^\d{3}\s?\d{3}\s?\d{3}$
Description
Social Insurance Number validator. Canadians only need apply. If somebody could help me (I'm bad at regex), I would like to modify this so that if there is one space after the 3rd digit (or 6th) then there must be one after the 6th (or third).
Matches
123 456 789 | 123456789 | 123 456789
Non-Matches
1234 5678 9 | 123 456 7890 | 123
Author Rating: Not yet rated. Matt Martens
Title Test Details Pattern Title
Expression
.*[Pp]en[Ii1][\$s].*
Description
Spam Stopper
Matches
penis
Non-Matches
na
Author Rating: Not yet rated. Alanski Perryman
Title Test Details Pattern Title
Expression
[\\s+,]
Description
Simple expression for matching all commas and all whitespace characters: ASCII (13,10,44)
Matches
, | whitespace | carrage returns
Non-Matches
cat
Author Rating: Not yet rated. andrew stone
Title Test Details Pattern Title
Expression
(?s)(?:\e\[(?:(\d+);?)*([A-Za-z])(.*?))(?=\e\[|\z)
Description
This expression will match all of the commands(escape codes) used in ANSI files. These are what were used to create the colors/blocks on BBS's for those of us that once dialed into them. http://www.wikipedia.org/wiki/ANSI_escape_code has a reference for ANSI escape codes. http://idledreams.net/lordscarlet/posts/153.aspx shows an example of the engine I have created surrounding the expression
Matches
Hello | Test | 
Non-Matches
abc
Author Rating: Not yet rated. Doug Moore
Title Test Details Pattern Title
Expression
(\b\w+\b) # Match a word and capture it \s+ \1 # Use backreference \1 to match double-ups
Description
Matches
This is is a match
Non-Matches
This isn't!
Author Rating: Not yet rated. Darren Neimke
Title Test Details Pattern Title
Expression
^[a-zA-Z]+(([\'\,\.\-][a-zA-Z])?[a-zA-Z]*)*$
Description
This allows you to validate first names and last names in seperate fields. Instead of validating a full name in one field.
Matches
Sameul | O'Conner | Mary-Kate
Non-Matches
David Bugel | Robert1 | Robert M. Larry
Author Rating: Not yet rated. Hayk A
Title Test Details Pattern Title
Expression
(NOT)?(\s*\(*)\s*(\w+)\s*(=|&lt;&gt;|&lt;|&gt;|LIKE|IN)\s*(\(([^\)]*)\)|'([^']*)'|(-?\d*\.?\d+))(\s*\)*\s*)(AND|OR)?
Description
Heres my sql clause parser regexp for recordset filtering. Does recursive query parsing all by its self. Only problem I cant figure is how to match comma separated lists of quoted strings. Tell me if you figure out how! The unicodes in the re was put in by the entry form please replace them with their ascii equivalents to use it.
Matches
Aeroplane LIKE 767 | Movie LIKE 'Star' AND NOT Movie LIKE 'Trek' | Number IN (1,2,3,4,5)
Non-Matches
Hello there | A=EXCELLENT OR | B!=POOR
Author Rating: Not yet rated. Joseph Warwick
Title Test Details Pattern Title
Expression
^([1-9]{1}[0-9]{3}[,]?)*([1-9]{1}[0-9]{3})$
Description
Matches a comma-seperated list of year(s).
Matches
1999,2001,1988 | 1999
Non-Matches
0199,1997 | 0199 | 1999,
Author Rating: Not yet rated. Craig Pearson
Title Test Details Pattern Title
Expression
^(?!000)(?!666)(?<SSN3>[0-6]\d{2}|7(?:[0-6]\d|7[012]))([- ]?)(?!00)(?<SSN2>\d\d)\1(?!0000)(?<SSN4>\d{4})$
Description
Updated on 3/4/2004 per feedback to additionally exclude SSNs that begin with 666 which, as reported, are also not valid. Regular expression for validating US Social Security Numbers. Accepts optional hyphens or spaces as formatting characters. Parses the three subfields of the SSN into three named sub-strings (SSN1, SSN2, and SSN3) to facilitate program use. Rejects matches on all zeros for any individual subfield of the Social Security Number. Matches only on those SSNs that fall within the range of numbers currently allocated by the Social Security Administration.
Matches
111223333 | 111-22-3333 | 111 22 3333
Non-Matches
111003333 | 111 22-3333 | 666-22-3333
Author Rating: Not yet rated. Jerry Schmersahl
Title Test Details Parse Comma Delimited Strings
Expression
^(?<field1>[^,]+),(?<field2>[^,]+),(?<field3>[^,]+)$
Description
Example of a regular expression that can be used to parse a comma delimited string into constituent, named sub-strings. Add or remove regex subfield definitions (?&lt;field1&gt;[^,]+) and corresponding delimiting characters in the regular expression as necessary to accommodate the string and subfields you intend to parse. Optionally, rename the subfield names in the regular expression to more meaningful names if you are using the parsed sub-strings in a program. Replace all occurrences of the comma in the regular expression with any required alternative delimiting character. As long as the delimiting character used does not occur naturally in any of the sub-strings, you should be good-to-go. NOTE: To change the delimiter character you must replace all occurrences of the comma in the current regex (of which there are 5) with the new delimiter character. e.g. (?&lt;field1&gt;[^;]+); changes the delimiter character to a semi-colon for the first field.
Matches
Fred,Barnie,Wilma | Bob,1/1/2003,222-3333 | 100,200,300
Non-Matches
Fred,Barnie,Wilma,Betty | Bob;1/1/2003;222-3333 | Tom Dick Harry
Author Rating: Not yet rated. Jerry Schmersahl
Title Test Details Pattern Title
Expression
(?n:(^(?(?![^,]+?,)((?<first>[A-Z][a-z]*?) )?((?<second>[A-Z][a-z]*?) )?((?<third>[A-Z][a-z]*?) )?)(?<last>[A-Z](('|[a-z]{1,2})[A-Z])?[a-z]+))(?(?=,)(, (?<first>[A-Z][a-z]*?))?( (?<second>[A-Z][a-z]*?))?( (?<third>[A-Z][a-z]*?))?)$)
Description
Regular expression for validating a person's full name. Matches on two general formats: 1) first second third last (where first, second, and third names are optional and all present are separated by a space); 2) last, first second third (where second and third are optional, last is followed immediately by a comma and a space, and second, and third, if present, are separated by a space from each other and from first). First corresponds to surname and last corresponds to family name. Each name part is captured to a named group to facilitate program manipulation. Each name part must begin with an uppercase letter, followed by zero or more lowercase letters, except for the last name. Last name must begin with an uppercase letter, followed by one or more lowercase letters, but will match exceptions formatted like the following: McD..., MacD..., O'R... Only format is validated, not spelling. NOTE: This regular expression uses positive and negative regex lookahead to determine the general format of the name, i.e. the presence or the absence of the comma determines the general format that will match. Furthermore, this initial version is not designed to accommodate titles and things like &quot;3rd&quot;.
Matches
John Paul Jones | Jones, John P | Jones
Non-Matches
Paul Jones, John | John J | Mr. John Paul Jones 3rd
Author Rating: Not yet rated. Jerry Schmersahl
Title Test Details Pattern Title
Expression
(&#161;|&#204;|&#205;|&#206;|&#207;|&#236;|&#237;|&#238;|&#239;|&amp;#033;|&amp;#161;|&amp;iexcl;|&amp;#185;|&amp;sup1;|&amp;brvbar;|&amp;Igrave;|&amp;Iacute;|&amp;Icirc;|&amp;Iuml;|&amp;igrave;|&amp;iacute;|&amp;iuml;|&amp;#204;|&amp;#205;|&amp;#206;|&amp;#207;|&amp;#236;|&amp;#237;|&amp;#238;|&amp;#239;|&amp;#073;|&amp;#105;)
Description
Spam stopper, catches any non english characters for i used in flocks
Matches
&#237;nvest today | &#206;s your | &#239;nto debt
Non-Matches
invest today | Is your | into debt
Author Rating: Not yet rated. Alanski Perryman
Title Test Details Pattern Title
Expression
(&#200;|&#201;|&#202;|&#203;|&#232;|&#233;|&#234;|&#235;|&amp;#069;|&amp;#101;|&amp;#200;|&amp;#201;|&amp;#202;|&amp;#203;|&amp;Egrave;|&amp;Eacute;|&amp;Ecirc;|&amp;Euml;|&amp;#232;|&amp;#233;|&amp;#234;|&amp;#235;|&amp;egrave;|&amp;eacute;|&amp;ecirc;|&amp;euml;)
Description
Spam stopper, catches non english characters used in flocks.
Matches
&#203;very one | &#203;nlarg&#235;m&#234;nt | b&#234;st &#235;ver
Non-Matches
Every one | Enlargement | best ever
Author Rating: Not yet rated. Alanski Perryman
Title Test Details Pattern Title
Expression
(&#192;|&#193;|&#194;|&#195;|&#196;|&#197;|&#224;|&#225;|&#226;|&#227;|&#228;|&#229;|&amp;#097;|&amp;#065;|&amp;#064;|&amp;commat;|&amp;alpha;|&amp;#192;|&amp;#193;|&amp;#194;|&amp;#195;|&amp;#196;|&amp;#197;|&amp;Agrave;|&amp;Aacute;|&amp;Acirc;|&amp;Atilde;|&amp;Auml;|&amp;Aring;|&amp;#224;|&amp;#225;|&amp;#226;|&amp;#227;|&amp;#228;|&amp;#229;|&amp;agrave;|&amp;aacute;|&amp;acirc;|&amp;atilde;|&amp;auml;|&amp;aring;)
Description
spam stopper, catches non english language flocks for letter A
Matches
ENL&#195;RGMENT | &#224;ll new | e&#227;sy go
Non-Matches
ENLARGMENT | all new | easy go
Author Rating: Not yet rated. Alanski Perryman
Title Test Details Pattern Title
Expression
(&#210;|&#211;|&#212;|&#213;|&#214;|&#216;|&#240;|&#242;|&#243;|&#244;|&#245;|&#246;|&#248;|&amp;#048;|&amp;#079;|&amp;#111;|&amp;#210;|&amp;#211;|&amp;#212;|&amp;#213;|&amp;#214;|&amp;#216;|&amp;Ograve;|&amp;Oacute;|&amp;Ocirc;|&amp;Otilde;|&amp;Ouml;|&amp;Oslash;|&amp;#242;|&amp;#243;|&amp;#244;|&amp;#245;|&amp;ograve;|&amp;oacute;|&amp;ocirc;|&amp;otilde;|&amp;ouml;|&amp;oslash;)
Description
Spam stopper, catches any non english characters used for o in flocks
Matches
&#212;nly $20 | &#216;ne t&#244; &#211;ne | g&#245;ing today
Non-Matches
Only $20 | One to one | going today
Author Rating: Not yet rated. Alanski Perryman
Change page:   |    Displaying page 3 of 5 pages; Items 41 to 60

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