non-numerical characters in cell phone field of a person's information

Go down

non-numerical characters in cell phone field of a person's information

Post  The Charles on Thu Apr 02, 2009 8:40 pm

http://www.daspecster.com/cam/index.php/person/show/id/1

I saved some wierd non-numerical characters in the cell phone field of this person without any complaint from symfony. Smile
avatar
The Charles

Posts : 54
Join date : 2009-01-12
Age : 36
Location : Berrien Springs, MI

View user profile http://www.myspace.com/qmart2001

Back to top Go down

Re: non-numerical characters in cell phone field of a person's information

Post  steven.oxley on Sat Apr 04, 2009 11:32 pm

How should we validate this? What if someone wants to put in something like:

(135) 461-2233 ext. 14 (Ask for Mary)

A lot of that would be non-numerical. Is that a problem? I think it's more informative than

135461223314

steven.oxley

Posts : 56
Join date : 2009-01-16
Age : 30
Location : India

View user profile http://stevenoxley.blogspot.com/

Back to top Go down

Re: non-numerical characters in cell phone field of a person's information

Post  tom.schultz on Sun Apr 05, 2009 2:05 am

Right, I think having alphanumeric values is ok in the phone field until we can make good validation code.

tom.schultz

Posts : 63
Join date : 2008-09-11

View user profile

Back to top Go down

Validation of Xters in the phone

Post  Kenny on Sun Apr 05, 2009 3:45 am

If a user enters a stream of alphanumeric Xters in a phone number, I think the code should only be concerned with the 10 numeric Xters found in the input stream. It searches for the numeric parts of the entry, not the alphabetic. Thus, this style 555-555-5555 or this style (555) 555-5555 should result into this style 5555555555.

In this way users have freedom of entering in any format.

--KK
avatar
Kenny

Posts : 14
Join date : 2008-09-29

View user profile

Back to top Go down

Re: non-numerical characters in cell phone field of a person's information

Post  steven.oxley on Mon Apr 06, 2009 1:07 am

Kenny wrote:If a user enters a stream of alphanumeric Xters in a phone number, I think the code should only be concerned with the 10 numeric Xters found in the input stream. It searches for the numeric parts of the entry, not the alphabetic. Thus, this style 555-555-5555 or this style (555) 555-5555 should result into this style 5555555555.

In this way users have freedom of entering in any format.

--KK

But this wouldn't allow for the scenarios I mentioned above where the user needs to specify an extension or to ask for a certain person. Granted, these scenarios would not happen too often (although the extension one is rather common). Also, you would be taking information away from the user's input.

steven.oxley

Posts : 56
Join date : 2009-01-16
Age : 30
Location : India

View user profile http://stevenoxley.blogspot.com/

Back to top Go down

Re: non-numerical characters in cell phone field of a person's information

Post  Kenny on Mon Apr 06, 2009 11:43 am

Thinking 1
While there are variations in which users can enter their data in various forms, it means one can specify the format for the user exactly what the program itself wants, and how it expects to find it, but the first 10 characters can help the program even if the extensions are not possible.

OR

Thinking 2
The first 10 Xters is of paramount interest, this should be noted, and if there exist further Xters appended after the first 10, the program should count them as extension, and act appropriately.
avatar
Kenny

Posts : 14
Join date : 2008-09-29

View user profile

Back to top Go down

Re: non-numerical characters in cell phone field of a person's information

Post  steven.oxley on Tue Apr 07, 2009 8:42 am

Kenny wrote:Thinking 1
While there are variations in which users can enter their data in various forms, it means one can specify the format for the user exactly what the program itself wants, and how it expects to find it, but the first 10 characters can help the program even if the extensions are not possible.
I don't think our application really cares what it finds in the telephone field (as long as it's not malicious javascript or something like that). Our application isn't going to be calling anyone. This field is meant for someone to be able to go back to it later and find out how to contact someone else on the telephone.
Kenny wrote:
Thinking 2
The first 10 Xters is of paramount interest, this should be noted, and if there exist further Xters appended after the first 10, the program should count them as extension, and act appropriately.
Why are the first 10 characters so important exactly? What are we going to do with those first 10 characters? What will our program do with them?

steven.oxley

Posts : 56
Join date : 2009-01-16
Age : 30
Location : India

View user profile http://stevenoxley.blogspot.com/

Back to top Go down

Re: non-numerical characters in cell phone field of a person's information

Post  Sponsored content


Sponsored content


Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum