And do, please, consider giving your eyes and sanity a huge break by thinking about using balanced delimiters — and maybe even some whitespace:
See perlre and perlretut, and m// s/// qr// qq// etc. in perlop.c:\@Work\Perl\monks>perl -wMstrict -le "my $xxx = 'YYY'; ;; my $boxtxt = 'aaa</boxed-text>bbb'; print qq{'$boxtxt'}; ;; $boxtxt =~ s{ </boxed-text> } {</new-stuff xxx${xxx}xxx>}xmsg; print qq{'$boxtxt'}; " 'aaa</boxed-text>bbb' 'aaa</new-stuff xxxYYYxxx>bbb'
In reply to Re: How to add perl variable before any text in perl code
by AnomalousMonk
in thread How to add perl variable before any text in perl code
by codewalker
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |