Last Updated: February 25, 2016
·
814
· michiels

Creating fancy money entry for your Rails app

You could just use regular integer inputs for allowing your users to input money amounts. But, it's a lot nicer if the input automatically translates a plain integer to a formatted string. So, 2000.23 becomes *2,000.23 while someone types in the form input.

Like this:

Money input preview

I wrote a blog post on how to do this. Take a look at: Creating fancy money entry for your Rails app.