velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Travis Low <tra...@dawnstar.org>
Subject Re: Formating data with Velocity
Date Sun, 15 Jul 2001 02:05:38 GMT
java.text.NumberFormat works...

cheers,

-- Travis Low
<mailto:travis@dawnstar.org>
<http://dawnstar.org/travis>



Geir Magnusson Jr. wrote:

> One Way wrote:
> 
>>Is there a way to format the data in Velocity, e.g. 123456.78 needs to
>>be shown as 123,456.78 or $123,456.78 in a web page.
>>
>>
> 
> Nothing in Velocity proper.  This would be the domain of what we call a
> 'context tool', a class put into the context for use by the template
> designer, such as 
> 
> $formatTool.currency( "123456.76")
> 
> There must be a library floating around somewhere to do this...
> 
> geir
> 
> 


-- 
-- Travis Low
    <mailto:travis@dawnstar.org>
    <http://dawnstar.org/travis>


Mime
View raw message