[Date Prev][Date Next][Thread Prev][Thread Next][Interchange by date
][Interchange by thread
]
[ic] problem with perl
hi,
I don't know PERL language, could you help me :
my scratch variable tva = .196 and [item-subtotal noformat=1] = 2500, then
my result is :
test : [scratch test] = 0
res : [scratch out] = 0
if i put $Safe{'scratch'}->{'var1'} = 196 / 1000 ; then my result is OK
test : [scratch test] = 0,196
res : [scratch out] = 490
this is my code :
[perl interpolate=1 arg='scratch values']
$Safe{'scratch'}->{'var1'} = '[scratch tva]';
$Safe{'scratch'}->{'var2'} = '[item-subtotal noformat=1]';
$_1 = $Safe{'scratch'}{'var1'};
$_= ($Safe{'scratch'}{'var2'} * $Safe{'scratch'}{'var1'}) ;
$Safe{'scratch'}{'test'} = $_1;
$Safe{'scratch'}{'out'} = $_;
return '';
[/perl]
Could you help to do the same thing with [scratch tva]
thanks
_______________________________________________
Interchange-users mailing list
Interchange-users@lists.akopia.com
http://lists.akopia.com/mailman/listinfo/interchange-users