Beefy Boxes and Bandwidth Generously Provided by pair Networks vroom
Just another Perl shrine
 
PerlMonks  

Re: Problem with regex

by blazar (Canon)
on Feb 03, 2005 at 05:28 UTC ( [id://427572]=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 Problem with regex

I tried this ($value) = $line =~ /.*test=(\d+)/; but this does not seem to be working.
In which way does it "seem not to work"? As mentioned by two other monks, it should! As a side note /test=(\d+)/ should be perfectly equivalent to your code...

Replies are listed 'Best First'.
Re^2: Problem with regex
by Jasper (Chaplain) on Feb 03, 2005 at 06:53 UTC
    Re: /.*test=(\d+)/ and /test=(\d+)/ ,of course, these are not entirely equivalent for other values of $line
      Now that I think about it you're right. Sorry for the imprecision...

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://427572]
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.