I’m looking for a regex that will allow me to validate whether or not a string is the reference to a website address, or a specific page in that website.
So it would match:
http://google.com ftp://google.com http://google.com/ http://lots.of.subdomains.google.com
But not:
http://google.com/search.whatever ftp://google.com/search.whatever http://lots.of.subdomains.google.com/search.whatever
Any ideas? I can’t quite figure out how to handle allowing the / at the end of the URL.
Try this: