Regular Expressions 101

Library entries

URL matching

Vote

0

Regular Expression
pcre

/
(?<protocol>(?:http|ftp|irc)s?:\/\/)?(?:(?<user>[^:\n\r]+):(?<pass>[^@\n\r]+)@)?(?<host>(?:www\.)?(?:[^:\/\n\r]+)(?::(?<port>\d+))?)\/?(?<request>[^?#\n\r]+)?\??(?<query>[^#\n\r]*)?\#?(?<anchor>[^\n\r]*)?
/
gmx

Description

Loading markdown...
Submitted by hjpotter92 - 7 years ago