in reply to Re: Template toolkit Adding Values to Variable
in thread Template toolkit Adding Values to Variable
Its my mistake i am changing it right now. i didnt write the proper code when i was makig simplified version to make my question more clear. but in fact it is [% totalprice = totalprice + ff %]. it seems like as i answered to " CountZero " , 'totalprice' variable become private when it is inside the
block because i printed the value inside the block and it does change but as soon it comes out of the block it retain the initial value ( the one before the [% FOREACH %]). i have tried to use [% BLOCK PROCESS %] but it still does not make any differnce. i might need to get the value from the script.[% FOREACH %]
But in your answer,dont you think it should be 'SET' what i have red in the ' Perl Template Toolkit ' book.
thanks
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Template toolkit Adding Values to Variable
by merlyn (Sage) on Mar 01, 2010 at 20:19 UTC | |
by seekperlwisdom (Acolyte) on Mar 01, 2010 at 21:34 UTC |