title: Regex for Mobile Number Validation
body: <p>I  want a regex for mobile number validation. The regex pattern should be such that it must accept <code>+</code> only in beginning and space(or <code>-</code>) should be allowed only after country code(only once). Only 10 digit number should be allowed after the country code. The country code should be optional. If country code doesn't exist, it should accept only 10 digit number. Regex should prevent any invalid number like (eg:<code>+91 0000000000</code> or <code>0000000000</code>).</p>
  
  <p><strong>The regex  should accept numbers like</strong></p>
  
  <ul>
  <li>+1 8087339090</li>
  <li>+91 8087339090</li>
  <li>+912 8087339090</li>
  <li>8087339090</li>
  <li>08087339090</li>
  <li>+1-8087339090</li>
  <li>+91-8087339090</li>
  <li>+912-8087339090</li>
  <li>+918087677876(Country code(2 digits) + 10 digits Mobile Number)</li>
  <li>+9108087735454(Country code(3 digits) + 10 digits Mobile Number)</li>
  </ul>
  
  <p><strong>The regex should not accept numbers like</strong></p>
  
  <ul>
  <li>++51 874645(double successive +)</li>
  <li>+71  84364356(double successive spaces)</li>
  <li>+91 808 75 74 678(not more than one space)</li>
  <li>+91 808-75-74-678(not more than one -)</li>
  <li>+91-846363</li>
  <li>80873(number less than 10 digit)</li>
  <li>8087339090456(number greater than 10 digit)</li>
  <li>0000000000(all zeros)</li>
  <li>+91 0000000(all zeros with country code)</li>
  </ul>