« Home



HTML Form Example: Phone Number Inputs with Auto-Forwarding

A client was using a 3 field phone number for looking up customer records. They wanted a "friendly" HTML form that automatically forwarded the user out of the field collecting the area code after 3 digits were entered, and into the phone prefix field, and again into the telephone suffix field. Further, they wanted to have some simple client-side javascript validation to regex pattern match the field input values to make sure they were numeric before bothering to submit the form to the server.

As this type of widget has become more popularly requested of late, I thought I'd share. Your feedback is appreciated.

( ) -




« Home