Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: using variables in regular expr replace

by Eimi Metamorphoumai (Deacon)
on Dec 02, 2004 at 17:53 UTC ( [id://411884]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    $line =~ s/\Q$var2\E/$var1/;
    
  2. or download this
    my $line = <<"HTML";
    <a href="/{HOST}?action">123</a>:</b><br>[img-smile "58-41" ":)"]
    HTML
    chomp $line;
    
  3. or download this
    my $line = qq#<a href="/{HOST}?action">123</a>:</b><br>[img-smile "58-
    +41" ":)"]#;
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (5)
As of 2024-04-23 21:52 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found