Re: [SMARTY] problem displaying float
[email protected] (Peggy Schatz) Fri, 17 Nov 2006 17:05:50 +0100
| Newsgroups | php.smarty.general |
|---|---|
| Message-ID | <[email protected]> |
Hi George,
maybe you did not assign $fee properly/at all...
There should be a line of code in your php-script like:
$smarty->assign('fee',$fee);
Within your template you then state {$fee} or as messju recommended
{"%.2f"|sprintf:$fee}
The latter modifies a string to get the proper number of floating values
(or however these are called)....
Hope that helps...
Peggy