News for hackers. Stuff that matters.
Re:Some Problems Shouldn't Be Solved by jdpage on Tuesday March 31, 2015 @09:34PM (#9301036)
There's especially no good excuse for CC or phone numbers, because they're all numbers. All you have to do is strip out anything that isn't a "significant" character (i.e. a digit or a letter), throw an error if any aren't digits, and throw an error if it isn't the right length. This algorithm is basically guaranteed* to behave exactly the way that everyone expects it to.

*I am not a UX engineer, YMMV

There are no comments on this comment yet.