title: jQuery Mobile: Numbers only input field?
body: <p>I'm making a website based on jQuery Mobile. On a particular field I would like to accept only numbers, or more precisely 4 digits. I noticed that the slider input does this (when you tap the field on your phone it brings up a "numbers only keyboard").</p>
  
  <p>However I'm not interested in the slider itself as this as I want the user to type in an exact number (for example 4687 is a bit hard to achive with a slider on a touch phone).</p>
  
  <p>Is there an alternative to the slider or is there a neat way to hide the actual slider?</p>
  
  <pre><code>&lt;div data-role="fieldcontain"&gt;
      &lt;fieldset data-role="controlgroup"&gt;
          &lt;label for="slc_length"&gt;
              Length
          &lt;/label&gt;
          &lt;input type="range" name="slider" id="slc_length" value="500" min="8" max="9999" data-highlight="true" /&gt;
      &lt;/fieldset&gt;
  &lt;/div&gt;
  </code></pre>