Live Telephone Number Validation | JavaScriptSource

Live Telephone Number Validation

Rob Sheldrake Mar 23, 2007


Simple telephone number validation. This script makes sure the user enters only numbers, brackets, hyphens, or spaces. A plus (+) may be entered as the first character. Just add it to your form validation routine.


Implement with onkeyup="validatephone(this);" on desired field

Add any symbols after the '@' symbol in the line of characters to block characters such as brackets

Source Code

Paste this source code into the designated areas.

External file

Paste this code into an external JavaScript file named: liveTeleNumValidation.js


Paste this code into the HEAD section of your HTML document.


Paste this code into the BODY section of your HTML document

Leave a Response


Thanks for sharing this.

suneel Oct 12, 2007

thats a nice code thanks dude.... :-)

lakshmi Sep 26, 2007

Its really helpful man... thank you..:-)[br /] Keep going...

raghunandan Jul 31, 2007

Hi.. it is very nice man, keep it up... It helps really helps for me a lot.[br /][br /]Thank you,[br /]Reddy Prasad

Reddy Prasad Jul 12, 2007

Great stuff,and very useful to me

Mujeeb Rahman Apr 1, 2007