Jump to content

The ultimate community for Ruby on Rails developers.


Photo

Working with currency

rails currency number_to_human

  • Please log in to reply
2 replies to this topic

#1 robzdc

robzdc

    Passenger

  • Members
  • 4 posts

Posted 21 November 2013 - 09:06 PM

Im using number_to_human for mexican currency, so I want to know if its possible to show something like 

 

$ 5 mil 500

 

instead of $ 5.5 mil

 

Thanks



#2 Ohm

Ohm

    Guard

  • Members
  • 179 posts
  • LocationCopenhagen

Posted 24 November 2013 - 11:50 AM

You should really use number_to_currency when dealing with currency. 

 

Documentation can be found here: http://api.rubyonrai...ber_to_currency


Blog: http://ohm.sh | Twitter: madsohm


#3 robzdc

robzdc

    Passenger

  • Members
  • 4 posts

Posted 25 November 2013 - 04:56 PM

Yeah I know that helper but that doesnt give me the value of $ 5 mil 500







Also tagged with one or more of these keywords: rails, currency, number_to_human

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users