match a phone number using regex code example
Example 1: phone patter regex
^(\+\d{1,2}\s)?\(?\d{3}\)?[\s.-]\d{3}[\s.-]\d{4}$
Example 2: phone number regex
^[+0]{0,2}(91)?[0-9]{10}$
^(\+\d{1,2}\s)?\(?\d{3}\)?[\s.-]\d{3}[\s.-]\d{4}$
^[+0]{0,2}(91)?[0-9]{10}$