RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Expressions by User

   Displaying page 1 of 1 pages; Items 1 to 1
Title Test Details Phone Number
Expression
^((\([2-9]\d{2}\)[ ]?)|([2-9]\d{2})[- ]?)\d{3}[- ]?\d{4}$
Description
Requires area code, optional parentheses but requires both. Allows '-' or ' '.
Matches
(555) 555-5555 | 555-555-5555 | 555 555-5555
Non-Matches
(555 555-5555, (555)-555-5555 | 555) 555-5555
Author Rating: Not yet rated. Brad Thomas
   Displaying page 1 of 1 pages; Items 1 to 1

Copyright © 2001-2025, RegexAdvice.com | ASP.NET Tutorials