constant TELEPHONE_REGEX in Phone 7
Same name and namespace in other branches
- 6 phone.eg.inc \TELEPHONE_REGEX
1 use of TELEPHONE_REGEX
- format_eg_phone_number in include/
phone.eg.inc
File
- include/
phone.eg.inc, line 55
Code
define('TELEPHONE_REGEX', "\n\t(\\+20)\\s\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t# optional countrycode optionally followed by a space\n\t\t(\n\t\t\t\t\\(2\\)\\s(2|3)\\d{3}\\s\\d{4}\t\t\t\t\t\t\t\t# 8-digit numbers begining with 2 or 3 (Greater Cairo: Cairo and Giza, both having area code = 2)\n\t\t\t|\n\t\t\t\t\\(" . AREA_CODE_REGEX . "\\)\\s\\d{3}\\s\\d{4}\t\t# all other areas' numbers have 7 digits. Checks for correct area codes\n\t\t\t|\n\t\t\t\t\\(" . MOBILE_CODE_REGEX . "\\)\\s\\d{3}\\s\\d{4}\t\t# mobile operators' networks' area codes; followed by 7 digits\n\t\t)\n\t\t(\\s\\#\\s\\d+)?\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t# optional extension number shown with a hash divider\n");