Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: regex a url

by count0 (Friar)
on Oct 06, 2002 at 03:39 UTC ( #203133=note: print w/replies, xml ) Need Help??


in reply to regex a url

An alternative directly using a regexp is to use the URI::URL (or even just the URI) module. This module is especially handy when when dealing with and manipulating URLs.
use URI::URL; my $url = URI::URL->new('http://www.merchandisemarket.net/shop/s_image +s/aaa_small.gif ') my ($filename) = ($url->path_segments)[-1];

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://203133]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (6)
As of 2016-09-28 23:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Extraterrestrials haven't visited the Earth yet because:







    Results (541 votes). Check out past polls.