Yes. Use a model method. Don't do serious calculation in templates. On Sun, Feb 19, 2012 at 11:03 AM, Jason <[email protected]> wrote: > Hi there, > > i'm currently using the widthratio tag for division within a django template > as detailed > here: http://slacy.com/blog/2010/07/using-djangos-widthratio-template-tag-for-multiplication-division/. > However, it only returns integer values. Is there something equally smart I > can use to return floats, as some of the numbers I am calculating are < 1 > and 0 gets returned... > > Cheers, > J > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To view this discussion on the web visit > https://groups.google.com/d/msg/django-users/-/GGL4EeyWFQsJ. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/django-users?hl=en.
-- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

