David Gilden wrote:
> 
> How do get  $i do increment inside the substitution below?
> 
> #!/usr/bin/perl -w
> 
> my $i = 0;
> 
> while(<>)
> {
> chomp;
> s/name=\"order/name=\"order$i++/;
> print "$_\n";
> }

Another way to do it:

s/name="order/name="order@{[$i++]}/;


John
-- 
use Perl;
program
fulfillment

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to