Get new jQuery plugins just once a week

×

formatter-js

FavoriteLoadingAdd to favorites

November 27, 2013

Format user input to match a specified pattern

formatter-js is a jQuery plugin that formats user input to match a specified pattern because it is useful to format user input as they type. Existing libraries lacked proper functionality / flexibility. Formatter was built from the ground up with no dependencies.

You can use any String representing the pattern of your formatted input. User input areas begin with {{ and end with }}. For example, a phone number may be represented: ({{999}}) {{999}}-{{999}}. You can specify numbers, letters, or numbers and letters.

Example Code :-

$('#credit-input').formatter({
'pattern': '{{999}}-{{999}}-{{999}}-{{9999}}',
'persistent': true
});

Created by Jarid Margolin

Download

Example

formatter-js jquery plugin

input patterns

formatter-js

Related posts:

Long Press
SCEditor
Leader.js
formatter-js jquery plugin

http://jquer.in/wp-content/uploads/2013/11/formatter-js.jpg

jQuery plugin

Sign up for our weekly newsletter.

* We won't spam you ever