Regular Expressions 101

Sponsors

Library entries

2
pcre

thy_reservations_names

no description available
Submitted by anonymous - 6 years ago
2
pcre

sun_reservation_flights

no description available
Submitted by anonymous - 6 years ago
2
pcre

sun-reservation-2-flights

no description available
Submitted by anonymous - 6 years ago
2
pcre

<a href=" replacer

to put # instead of url
Submitted by mrBakop - 6 years ago
2
pcre

DateWithDay

no description available
Submitted by BobD - 6 years ago
2
pcre

IPv4 strict

Valid: 000.01.249.255 1.199.200.0 0.0.0.0 Invalid:...
Submitted by MaxusR - 6 years ago
2
pcre

desanonimyse

no description available
Submitted by JB Escudié - 6 years ago
2
pcre

MONTHDAY

no description available
Submitted by anonymous - 6 years ago
2
pcre

hex number check

check if a string is a hex number
Submitted by anonymous - 6 years ago
2
pcre

Numéro de sécurité sociale (France)

no description available
Submitted by Anas - 6 years ago
2
pcre

get all between 2 lines

no description available
Submitted by anonymous - 6 years ago
2
pcre

Positive Ints

no description available
Submitted by anonymous - 6 years ago
2
pcre

mikrotik

no description available
Submitted by anonymous - 6 years ago
2
pcre

Diiff

no description available
Submitted by anonymous - 6 years ago
2
pcre

the many john smiths

no description available
Submitted by anonymous - 6 years ago

Matching email addresses per RFC5322

Vote

230

Regular Expression
pcre

/
(?(DEFINE) (?<addr_spec> (?&local_part) @ (?&domain) ) (?<local_part> (?&dot_atom) | (?&quoted_string) | (?&obs_local_part) ) (?<domain> (?&dot_atom) | (?&domain_literal) | (?&obs_domain) ) (?<domain_literal> (?&CFWS)? \[ (?: (?&FWS)? (?&dtext) )* (?&FWS)? \] (?&CFWS)? ) (?<dtext> [\x21-\x5a] | [\x5e-\x7e] | (?&obs_dtext) ) (?<quoted_pair> \\ (?: (?&VCHAR) | (?&WSP) ) | (?&obs_qp) ) (?<dot_atom> (?&CFWS)? (?&dot_atom_text) (?&CFWS)? ) (?<dot_atom_text> (?&atext) (?: \. (?&atext) )* ) (?<atext> [a-zA-Z0-9!#$%&'*+\/=?^_`{|}~-]+ ) (?<atom> (?&CFWS)? (?&atext) (?&CFWS)? ) (?<word> (?&atom) | (?&quoted_string) ) (?<quoted_string> (?&CFWS)? " (?: (?&FWS)? (?&qcontent) )* (?&FWS)? " (?&CFWS)? ) (?<qcontent> (?&qtext) | (?&quoted_pair) ) (?<qtext> \x21 | [\x23-\x5b] | [\x5d-\x7e] | (?&obs_qtext) ) # comments and whitespace (?<FWS> (?: (?&WSP)* \r\n )? (?&WSP)+ | (?&obs_FWS) ) (?<CFWS> (?: (?&FWS)? (?&comment) )+ (?&FWS)? | (?&FWS) ) (?<comment> \( (?: (?&FWS)? (?&ccontent) )* (?&FWS)? \) ) (?<ccontent> (?&ctext) | (?&quoted_pair) | (?&comment) ) (?<ctext> [\x21-\x27] | [\x2a-\x5b] | [\x5d-\x7e] | (?&obs_ctext) ) # obsolete tokens (?<obs_domain> (?&atom) (?: \. (?&atom) )* ) (?<obs_local_part> (?&word) (?: \. (?&word) )* ) (?<obs_dtext> (?&obs_NO_WS_CTL) | (?&quoted_pair) ) (?<obs_qp> \\ (?: \x00 | (?&obs_NO_WS_CTL) | \n | \r ) ) (?<obs_FWS> (?&WSP)+ (?: \r\n (?&WSP)+ )* ) (?<obs_ctext> (?&obs_NO_WS_CTL) ) (?<obs_qtext> (?&obs_NO_WS_CTL) ) (?<obs_NO_WS_CTL> [\x01-\x08] | \x0b | \x0c | [\x0e-\x1f] | \x7f ) # character class definitions (?<VCHAR> [\x21-\x7E] ) (?<WSP> [ \t] ) ) ^(?&addr_spec)$
/
xmg

Description

Loading markdown...
Submitted by Michael Musson - 9 years ago