function valid_pa_phone_number in Phone 6
Same name and namespace in other branches
- 7 include/phone.pa.inc \valid_pa_phone_number()
Verifies that $phonenumber is a valid nine-digit Panamanian phone number
Parameters
string $phonenumber:
Return value
boolean Returns boolean FALSE if the phone number is not valid.
1 call to valid_pa_phone_number()
File
- ./
phone.pa.inc, line 41 - CCK field for Panamanian phone numbers
Code
function valid_pa_phone_number($phonenumber) {
//$phonenumber = trim($phonenumber);
// define regular expression
// return true if valid, false otherwise
return (bool) preg_match(PHONE_PA_REGEX, $phonenumber);
}