Update regex
This commit is contained in:
parent
1bd7627414
commit
caa9d6ff09
1 changed files with 9 additions and 1 deletions
|
@ -79,4 +79,12 @@
|
|||
("(a-z)" "a, - and z")
|
||||
("(\s+|,)" "spaces or a comma")
|
||||
("#\w+" "find hashtags")
|
||||
("([@|#]\w+)" "matches both mentions (@) and hashtags")))
|
||||
("([@|#]\w+)" "matches both mentions (@) and hashtags")
|
||||
("(^[a-zA-Z0-9_.+-]+@[a-zA-Z0-9-]+\.[a-zA-Z0-9-.]+$)" "email regex")
|
||||
("-?\d+(\.\d*)?" "matching decimal numbers")
|
||||
("(?:http|https|ftp|mailto|file|data|irc):\/\/[A-Za-z0-9\-]{0,63}(\.[A-Za-z0-9\-]{0,63})+(:\d{1,4})?\/*(\/*[A-Za-z0-9\-._]+\/*)*(\?.*)?(#.*)?" "matching urls")
|
||||
("^\d{4}/(0[1-9]|1[0-2])/(0[1-9]|[12][0-9]|3[01])$" "matching dates yyyy/mm/dd")
|
||||
("^(0[1-9]|1[0-2])/(0[1-9]|[12][0-9]|3[01])/\d{4}$" "matching dates mm/dd/yyyy")
|
||||
("^(0[1-9]|[12][0-9]|3[01])/(0[1-9]|1[0-2])/\d{4}$" "matching dates dd/mm/yyyy")
|
||||
("<.+>" "matching html")
|
||||
("<\/?(?:p|a|b|img)(?: \/)?>" "matchig specific tags")))
|
||||
|
|
Loading…
Add table
Reference in a new issue