I want to validate Indian phone numbers as well as mobile numbers. The format of the phone number and mobile number is as follows:
For land Line number
03595-259506 03592 245902 03598245785
For mobile number
9775876662 0 9754845789 0-9778545896 +91 9456211568 91 9857842356 919578965389
I would like the regular expression in one regex. I have tried the following regex but it is not working properly.
{^\+?[0-9-]+$}
Mobile Number validation criteria: The first digit should contain number between 7 to 9. The rest 9 digit can contain any number between 0 to 9. The mobile number can have 11 digits also by including 0 at the starting. The mobile number can be of 12 digits also by including 91 at the starting.
Regular expression to allow numbers like +111 123 456 789: ^(\\+\\d{1,3}( )?)?(\\d{3}[ ]?){2}\\d{3}$
For land Line Number
03595-259506 03592 245902 03598245785
you can use this
\d{5}([- ]*)\d{6}
NEW for all ;)
OLD: ((\+*)(0*|(0 )*|(0-)*|(91 )*)(\d{12}+|\d{10}+))|\d{5}([- ]*)\d{6} NEW: ((\+*)((0[ -]*)*|((91 )*))((\d{12})+|(\d{10})+))|\d{5}([- ]*)\d{6} 9775876662 0 9754845789 0-9778545896 +91 9456211568 91 9857842356 919578965389 03595-259506 03592 245902 03598245785
this site is useful for me, and maby for you .;)http://gskinner.com/RegExr/
Use the following regex
^(\+91[\-\s]?)?[0]?(91)?[789]\d{9}$
This will support the following formats:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With