title: IP masking HTML input form with jQuery
body: <p>So I need to validate an input field to accept IP addresses.</p>
  
  <pre><code>&lt;form method="POST"&gt;
      &lt;input type='text' placeholder='xxx.xxx.xxx.xxx' name='IP'&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>Since there is no IP value for the attribute <code>type</code>, I would need to validate it using <strong>Javascript</strong> or some client-sided language. I've reached to this <strong>jQuery</strong> snippet using a <a href="https://raw.githubusercontent.com/digitalBush/jquery.maskedinput/1.3.1/dist/jquery.maskedinput.js" rel="nofollow">mask library</a>.</p>
  
  <pre><code>jQuery(function($){
     $("input").mask("9?99.9?99.9?99.9?99", {placeholder:" "});
  });
  </code></pre>
  
  <p>This however doesn't work on my side. Here is how I include the scripts <em>(just to point out)</em>.</p>
  
  <pre><code>&lt;script src="http://code.jquery.com/jquery-1.11.0.min.js" type="text/javascript"&gt;&lt;/script&gt;
  &lt;script src="https://raw.githubusercontent.com/digitalBush/jquery.maskedinput/1.3.1/dist/jquery.maskedinput.js" type="text/javascript"&gt;&lt;/script&gt;
  </code></pre>
  
  <p>Also, even if I manage to make this work, it still isn't the best option since two-digit parts of an IP address won't be rendered properly <em>(i.e. 84.55.11.499)</em>. So my questions are:</p>
  
  <ol>
  <li>Why does the above code not work on my end but does on <strong>JSFiddle</strong>?</li>
  <li>How do I filter two-digit IP addresses with the <strong>mask library</strong>?</li>
  </ol>