ad_page_contract_filter_proc_phone (public)

 ad_page_contract_filter_proc_phone name value_varname

Defined in packages/acs-tcl/tcl/tcl-documentation-procs.tcl

Checks whether the value is more or less a valid phone number with the area code. Specifically, area code excluding leading "1", optionally enclosed in parentheses; followed by phone number in the format xxx xxx xxxx (either spaces, periods or dashes separating the number). This filter matches the beginning of the value being checked, and considers any user input following the match as valid (to allow for extensions, etc.). Add a $ at the end of the regexp to disallow extensions. Examples:

  • (800) 888-8888 will pass
  • 800-888-8888 will pass
  • 800.888.8888 will pass
  • 8008888888 will pass
  • (800) 888-8888 extension 405 will pass
  • (800) 888-8888abcd will pass
  • "" (the empty string) will pass
  • 1-800-888-8888 will fail
  • 10-10-220 800.888.8888 will fail
  • abcd(800) 888-8888 will fail

Parameters:
name
value_varname
Author:
Randy Beggs <randyb@arsdigita.com>
Created:
August 2000

Partial Call Graph (max 5 caller/called nodes):
%3 test_ad_page_contract_filters ad_page_contract_filters (test acs-tcl) ad_page_contract_filter_proc_phone ad_page_contract_filter_proc_phone test_ad_page_contract_filters->ad_page_contract_filter_proc_phone _ _ (public) ad_page_contract_filter_proc_phone->_ ad_complain ad_complain (public) ad_page_contract_filter_proc_phone->ad_complain

Testcases:
ad_page_contract_filters
[ show source ]
Show another procedure: