URI will not do the trick, since it accepts both absolute and relative URIs, and it doesn't do validation.
For example, "www.example.com" is accepted (even though it's not a valid absolute URI), ":80" and "http://:80" are accepted (even though they are not valid URIs).
In reply to Re^2: regex to match URLs
by ikegami
in thread regex to match URLs
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |