5 ms·
Why use any pattern? Let me enter the phone number in a way I got used to it and deal with it.
by snitko 17y ago
Why use any pattern? Let me enter the phone number in a way I got used to it and deal with it.
- raganwald 17y agoThere's a cost/benefit analysis to be done. People do make mistakes, and checking their submission against common patterns will save you lost sales. As suggested in a comment on a rant I wrote a few years ago, one strategy is to 'validate' against something reasonable, but instead of rejecting anything that fails, ask the user to confirm that they really do want something unexpected. I'm not sure that 'reasonable' would be for an international phone number, but whatever you pick based on the country they choose, let them override your validation.
- jacoblyles 17y agoWell, I suppose you could just validate numbers from the most common countries you see and hope the rest don't make mistakes. Call it the Amdahl's law of internationalization.
- barrkel 17y agoConfirmation is OK, but taking a hard line is a no-no. I've had endless problems trying to jam my Irish mobile phone number (for a long time, my primary phone) into UK phone number fields.
- sigzero 17y agoUmmm...no. Do you not see the problem with that reasoning?
- Vivtek 17y agoWhat, the whole "being able to place an order even if you're not American" thing?
- whyenot 17y agoI'm not snitko, but I don't see the problem. Could you please explain your reasoning?
- Semiapies 17y agoTo be blunt, inputs you don't validate are inputs that will be entered wrong a significant portion of the time. Other concerns may override this for many fields, but unusable phone numbers are generally considered a problem.
- whyenot 17y agoYes, but if you over-validate you also risk losing sales. What to do doesn't seem obvious at all, at least to me. You'd want to do some kind of cost-benefit analysis Also, wouldn't a phone number in effect be validated for most online credit card purchases? I thought credit card processor often match the phone number you provide to the phone number on record for your account to prevent fraud. Skip the javascript validation, and let the cc processor validate the phone number. ...but I have no idea what I'm talking about, please correct me if I'm wrong.
- Semiapies 17y agoIt's not universally true, no. If you under-validate, you risk sales you can't complete. Mind, that's less dire when you have email addresses - but we know the problems with trying to validate those on forms.
- mattm 17y agoIf you force people to enter a phone number in a format they don't have, you will just end up with a bunch of 555-555-5555 numbers. Either way, you are going to get incorrect information. It's much better to realise that your information will not always be 100% accurate no matter what you do.
- Semiapies 17y agoThe idea is to minimize incorrect information. A 555 number at least tells you something that a number in an unfamiliar format doesn't - whether this was intentional or mistyped. I'm very much for allowing people to enter any format, but seeing how badly people mis-enter NANPA phone numbers, it is simply wrong to not acknowledge that you will see far more mistakes from an open input box.
- bobbyi 17y agoBecause that's scary for users who have anxiety worrying they didn't input things correctly. If you tell them the phone number format and have a state dropdown, people rest easy knowing you will get their contact info correct.