in reply to Re: Re: Regex to match file extension in URL
in thread Regex to match file extension in URL
Of course, this won't work for URL's with an implicit filename, like "http://www.yahoo.com" or "http://www.somewhere.com/home/" You'll have to catch those bad boys elsewhere in your code.if ($myvar =~ m/\.([^.]+)$/) { print "Matched $1"; }
Gary Blackburn
Trained Killer
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: Re: Regex to match file extension in URL
by Amoe (Friar) on Sep 09, 2001 at 17:15 UTC | |
by Trimbach (Curate) on Sep 09, 2001 at 19:07 UTC |