function _pl_regex in Phone Number 6
Same name and namespace in other branches
- 7 includes/phone.pl.inc \_pl_regex()
Polish phone number regex helper.
2 calls to _pl_regex()
- pl_validate_number in includes/
phone.pl.inc - Verifies that $number is a valid 9-digit Polish phone number.
- _pl_formatter in includes/
phone.pl.inc - Helper for formatting output. Output as +48 (AA) BBB CCCC
File
- includes/
phone.pl.inc, line 11 - CCK Field for Polish phone numbers.
Code
function _pl_regex() {
return '/^
([1-9]\\d) # 2-digit area code
([1-9]\\d{2}) # 3-digit phone prefix (cannot start with 0)
(\\d{4})
$/x';
}