Regular Expressions 101

Community Patterns

testing for a bloke

1

Regular Expression
PCRE (PHP <7.3)

/
((?<!href=')(?<!href=")(www\.|(http|https|ftp|news|file)+\:\/\/)[&#95;.a-z0-9-]+\.[a-z0-9\/&#95;:@=.+?,##%&~-]*[^.|\'|\\||\# |!|\(|?|\[|,| |>|<|;|\)])
/
g

Description

Parsing html with regex is bad though.

Submitted by Iroh - 9 years ago