Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: How do I avoid double substitution when replacing many patterns?

by barbie (Deacon)
on Jan 26, 2007 at 15:55 UTC ( #596737=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    use Data::Phrasebook;
    my $pb = Data::Phrasebook->new( file => 'phrases.txt' );
    my $str = $pb->fetch( 'baz', {foo => '${bar}', bar => '${foo}'} );
    # $str = 'foo is ${bar} and bar is ${foo}'
    
  2. or download this
    baz=foo is :foo and bar is :bar
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (12)
As of 2015-03-27 19:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    When putting a smiley right before a closing parenthesis, do you:









    Results (619 votes), past polls