Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: How do i interpolate a variable in a regular expression?

by reneeb (Chaplain)
on Sep 27, 2006 at 06:54 UTC ( #575095=note: print w/ replies, xml ) Need Help??


in reply to How do i interpolate a variable in a regular expression?

You should use the qr-operator:

my %config = ( URI => { regex => qr/^$method\ssip:/, sub => \&request_line }, )


see perldoc perlop


Comment on Re: How do i interpolate a variable in a regular expression?
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (7)
As of 2014-12-21 22:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (108 votes), past polls