Copy the code as follows:
1. php mobile phone number verification (supporting local query and encoding UTF8) _ PHP Tutorial
Description: php verifies the mobile phone number (which can be found by region and encoded as UTF8 ). The code is as follows :? Php // mobile phone number verification function checkMobileValidity ($ mobilephone) {$ exp = "/^ 13 [0-9] {1} [0-9] {8} $ | 15 [012356789] {1} [0-9] {8} $ | 18 [012356789] {1} [0-9] {8} $ | 14 [
2. php regular expression verification-PHP mobile phone number verification (, 18)
Introduction: php regular expression verification-PHP mobile phone number verification (, 18)
3. verify the mobile phone number in php (the local query and encoding are supported as UTF8)
Introduction: This article will implement the following functions: mobile phone number verification/conversion string encoding to UTF8. if you are interested in this, please refer to, maybe this article will help you
4. find the js code to verify the mobile phone number entered by the user and pass in the background code
Introduction: The front-end page is as follows {code ...} the method bit sendVerifyMessage is sent in the background. the corresponding route is domain/send-verify-message. the js code can verify the mobile phone number entered by the user and pass in the background code.
5. verify the mobile phone number in php to determine the location of the mobile phone number
Introduction :? Php // mobile phone number verification function checkMobileValidity ($ mobilephone) {$ exp =/^ 13 [0-9] {1} [0-9] {8} $ | 15 [012356789] {1} [0-9] {8} $ | 18 [012356789] {1} [0-9] {8} $ | 14 [57] {1} [0-9] $ /; if (preg_match ($ exp, $ mobilephone) {return true;} else {return false;} // return the mobile phone number
6. PHP mobile phone number verification function (, 18)
Introduction: no details, no/*** verify whether it is a mobile phone number ** @ param string $ phone number to be verified * @ return boolean if verification fails, false is returned, returns true */function isTelNumber ($ phone) {if (strlen ($ phone )! = 11 |! Preg_match ('/^ 1 [3 | 4 | 5 | 7 | 8] [0-9] d {4, 8} $
7. php mobile phone number verification (supports local location query and UTF-8 encoding) _ php skills
Introduction: This article will implement the following functions: mobile phone number verification/conversion string encoding to UTF8. if you are interested in this, please refer to, maybe this article will help you
The above is a summary of the usage of mobile phone number verification instances in php. For more information, see other related articles in the first PHP community!