Beefy Boxes and Bandwidth Generously Provided by pair Networks Joe
laziness, impatience, and hubris
 
PerlMonks  

Re^2: Fetching last part of url

by CombatSquirrel (Hermit)
on Sep 09, 2004 at 13:10 UTC ( [id://389787]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to Re:Fetching last part of url
in thread Fetching last part of url

#!perl use strict; use warnings; my $myfetch = 'http:\\myurlinfo\mypage.html'; $myfetch =~ m!([^/!]*$)! ? print $1 : print 'Whoops...'; __END__ Unmatched [ in regex; marked by <-- HERE in m/([ <-- HERE ^// at (eval + 1) line 7.
Probably you meant
#!perl use strict; use warnings; my $myfetch = 'http:\\myurlinfo\mypage.html'; $myfetch =~ m!([^\\]+)$! ? print $1 : print 'Whoops...'; __END__ mypage.html

Cheers,
CombatSquirrel.

Entropy is the tendency of everything going to hell.

Replies are listed 'Best First'.
Re^3: Fetching last part of url
by borisz (Canon) on Sep 09, 2004 at 13:16 UTC
    Oops, no I mean m!([^/]*$)! sorry.
    Boris

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://389787]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.