Get new jQuery plugins just once a week
May 19, 2014
NumBox | Mobile-Friendly HTML5 Numeric Input
NumBox is a mobile-friendly html5 numeric input plugin that aims to work equally well on desktops and mobile devices, and helps ensure that a numeric keyboard will pop-up on mobile devices when a number is entered. It offers both real-time validation as you type plus display formatting, and has a lot of customization options. For example, you could set up NumBox to handle a custom currency with your choice of decimal places, minimum and maximum values, currency symbol and if the symbol goes before or after the value. When displayed, (not focused for input,) the number is correctly formatted with the appropriate symbol and commas every three digits, etc. During input, as you press each key, before it is displayed, the key press is validated, so you can’t enter non-numeric characters, numbers that are greater or smaller than the allowed range, or a number with an inappropriate number of decimal places, etc.
NumBox has got the following features :-
- Input filtering and formatting of HTML5 type=”number” inputs.
- Helps ensure numeric keyboard appears on mobiles for entry.
- Assists in ensuring input box stays in viewport during entry.
- Does not rely on spinners, which can optionally be hidden.
- Mobile-first design also works on desktops, including IE6+.
- Extremely light weight at 2.62KB of code gzipped.
- Provides both formatted value and numeric value.
- Provides optional event hooks for your own code.
- As-you-type real-time validation doesn’t rely on browser.
- Custom formatting of displayed numbers.
- Localizable: currency symbol, location, etc.
- Fully compatible with PhoneGap and Apache Cordova.
- Fully compatible with jQuery Mobile & other frameworks.
- Requires either jQuery 1.7+ or Zepto.js v1.0+.
- Free license for both commercial and non-commercial use.
Created by Neil Cresswell
Sign up for our weekly newsletter.
10 Most Amazing Couple Gifts
A comprehensive guide to couple gift Ideas for Valentine’s Day, Weddings, Anniversaries for your spouse, friend, fiance, boyfriend / girlfriend.
Take me there !
Continue to jquer.in