Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
A simple spinner for number inputs in jQueryMobile
JavaScript Python
branch: master

This branch is 5 commits behind jtsage:master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
build
external
js
README.md
index.html

README.md

jQuery-Mobile-Spinbox

Spinbox is a jQuery-mobile based number spinner. Full Documentation and Demos

The spinbox control is simple to use - just load the script after jQM, and set your data-type="spinbox". Initial input type can be whatever you want, nothing is changed - min/max are enforced with the buttons.

<script type="text/javascript" src="http://code.jquery.com/jquery-1.7.1.min.js"></script> 
<script type="text/javascript" src="http://code.jquery.com/mobile/latest/jquery.mobile.min.js"></script>

<!-- Optional Mousewheel support: http://brandonaaron.net/code/mousewheel/docs -->
<script type="text/javascript" src="PATH/TO/YOUR/COPY/OF/jquery.mousewheel.min.js"></script>

<script type="text/javascript" src="http://dev.jtsage.com/cdn/spinbox/latest/jqm-spinbox.min.js"></script>

A typical input:

<div class="ui-field-contain">
    <label for="spin">Input spinner</label>
    <input type="text" data-role="spinbox" name="spin" id="spin" value="60" min="0" max="100" />
</div>
Something went wrong with that request. Please try again.