Go Back  HTML Forums - Free Webmaster Forums and Help Forums > WEBSITE DEVELOPMENT > Client Side Scripting
User Name:
Password:
 

Reply
Thread Tools   Display Modes
  View First Unread
 
Old 09-15-2005, 04:18 PM
  #1
lei
Myrmidon (Level 12)
 
lei's Avatar
 
Join Date: May 2004
Location: Arizona
Posts: 171
iTrader: (0)
lei is on a distinguished road
Javascript Phone Number Vailidation

i am wondering if anyone knows of a script that i won't have to edit (i'm not good at scripting) that can be used to validate a phone number in a form....we are running into issues with people not entering valid information in the phone number field....

thank you
lei is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 09-15-2005, 04:31 PM
  #2
_Aerospace_Eng_
The CSS Master (somewhat)
 
_Aerospace_Eng_'s Avatar
 
Join Date: Dec 2004
Location: In a galaxy far far away...
Posts: 11,154
iTrader: (0)
_Aerospace_Eng_ has disabled reputation
Is there a length that the number has to be? Basically what would be considered valid?
__________________

76 invites left. PM me for a Gmail invite along with email addy.
Why we won't help you .::. Web Developer's Handbook .::. Why Tables for Layout is Stupid?
_Aerospace_Eng_ is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 09-15-2005, 05:46 PM
  #3
lei
Myrmidon (Level 12)
 
lei's Avatar
 
Join Date: May 2004
Location: Arizona
Posts: 171
iTrader: (0)
lei is on a distinguished road
it should of course be numerical and contain an area code...10 digits at the very least
lei is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 09-16-2005, 08:35 AM
  #4
RysChwith
Super Guru
 
Join Date: Jun 2004
Posts: 4,117
iTrader: (0)
RysChwith will become famous soon enough
Apple has a really good article on form validation, that has downloadable code to go with it:

http://developer.apple.com/internet/...alidation.html

You know, much as I maintain my irrational dislike of the company, their developer site is really good.

Rys
RysChwith is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 09-16-2005, 10:11 AM
  #5
Bill Posters
Catapulted
 
Join Date: May 2003
Posts: 610
iTrader: (0)
Bill Posters is on a distinguished road
The regexlib.com site may prove helpful as it offers a range of suggested regular expression (regex) patterns which can be used when validating a range of form data types including telephone numbers.

Additionally, I'd recommend displaying a correctly formatted, sample telephone number next to the telephone entry field(s).

Last edited by Bill Posters : 09-16-2005 at 10:14 AM.
Bill Posters is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote

Reply
KEEP TABS
SPONSORS
 
Boxedart
 
 


 
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
  
 
 
 



 
  POSTING RULES
 
 
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Thread Tools
Display Modes

Forum Jump

 

All times are GMT -5. The time now is 11:34 AM.

   

Mascot team created by Drawshop.com

Powered by vBulletin® Version 3.6.7
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.

Server Monitoring by ENIACmonitor 0.01
HTMLforums.com © Big Resources, Inc. Web Design by BoxedArt.com
vRewrite 1.5 beta SEOed URLs completed by Tech Help Forum and Chalo Na.