title: Check range of IP address using javascript reqular expression only
body: <p>I want to check the range of ip address  in a regular expression ,
  I was using this way and it's working so successfully </p>
  
  <pre><code>function validate_ip(ip)
  {
         // See if x looks like an IP address using our "almost IP regex".
      var regex = /^(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})$/;
      var match = regex.exec(ip);
      if (!match) return false;
      // Additional code to check that the octets aren't greater than 255:
      for (var i = 1; i &lt;= 4; ++i) {
          if (parseInt(match[i]) &gt; 255) 
              return false;
      }
      return true;
  }
  </code></pre>
  
  <p>now i want to perform checking of the range and the syntax in just regular expression 
  can this be done ? </p>