https://github.com/marcelod/jquery-maskmoney
jQuery plugin to mask data entry in the input text in the form of money (currency).
https://github.com/marcelod/jquery-maskmoney
Last synced: 8 months ago
JSON representation
jQuery plugin to mask data entry in the input text in the form of money (currency).
- Host: GitHub
- URL: https://github.com/marcelod/jquery-maskmoney
- Owner: marcelod
- Fork: true (plentz/jquery-maskmoney)
- Created: 2012-09-05T12:33:19.000Z (almost 14 years ago)
- Default Branch: master
- Last Pushed: 2012-09-05T13:53:17.000Z (almost 14 years ago)
- Last Synced: 2024-10-02T08:19:34.474Z (over 1 year ago)
- Language: JavaScript
- Homepage:
- Size: 123 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Just a simple way to create masks to your currency form fields with [jQuery](http://jquery.com/).
***
### Show Time!
To view a complete demonstration of it's features and usage, access our [examples page](http://plentz.org/maskmoney)!
***
### Usage:
``` html
$(function(){
$("#currency").maskMoney();
})
```
***
### Options:
The options that you can set are:
* symbol: the symbol to be used before of the user values. default: 'US$'
* showSymbol: set if the symbol must be displayed or not. default: false
* symbolStay: set if the symbol will stay in the field after the user exists the field. default: false
* thousands: the thousands separator. default: ','
* decimal: the decimal separator. default: '.'
* precision: how many decimal places are allowed. default: 2
* defaultZero: when the user enters the field, it sets a default mask using zero. default: true
* allowZero: use this setting to prevent users from inputing zero. default: false
* allowNegative: use this setting to prevent users from inputing negative values. default: false
***
### Bonus!
We have 2 bonus methods that can be useful to you:
* .unmaskMoney() which removes maskMoney from an element.
* .mask() which causes maskMoney to actually apply the mask to your input.
***
### Contributors:
* [Aurélio Saraiva](mailto:aureliosaraiva@gmail.com)
* [Raul Pereira da Silva](http://raulpereira.com)
* [Diego Plentz](http://plentz.org)
* [Otávio Ribeiro Medeiros](http://github.com/otaviomedeiros)
* [Víctor Cruz](http://github.com/xtream)
* [Synapse Studios](http://github.com/synapsestudios)
* [Guilherme Garnier](http://blog.guilhermegarnier.com/)
* [Plínio Balduino](http://github.com/pbalduino)
***
### License:
__jQuery-maskMoney__ is released under the MIT license.