We don't bite newbies here... much | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
Regarding: Well, I thought doing a s//e on it would be the ticket, but apparently not.
It takes a little extra work, but it is certainly do-able... The double /ee is needed. The first /e sub's in the value of $rpl. The second /e evaluates that and DWIM's. The nested quotes are needed in defining $rpl because without the inner double-quotes, the second /e fails. Another way to do that bit (and this may help in understanding) would be: my $rpl = '"read" . $1'; You have to get both the quoting and the /ee right for the thing to work as intended. HTH
------------------------------------------------------------
In reply to Re: Re: evaluating $1 in a replace string
by dvergin
|
|