3 ms·
> Try 1/20 in the MM/YY field. Doesn't work. i've never seen a card that specified expiration month with a single digit. google images for "card expiration" do
by leeoniya 8y ago
> Try 1/20 in the MM/YY field. Doesn't work.
i've never seen a card that specified expiration month with a single digit. google images for "card expiration" does not bring up any examples either. a placeholder="MM/YY" should make it clear that both are needed.
- teknopaul 8y agoFYI Firefox mobile was unable to enter dates in January. I agree this is bad practice. I have similar code in an app I'm writing right now, I also didn't consider the usability issues or wierd delete cases. Gonna remove the code after reading this thread. Falls under trying to be clever. I think slightly increasing the space between groups of numbers might be acceptable? Anything that magically inserts characters seems to be problematic.
- jeroenhd 8y agoTo humans, 01 is the same as 1. To computers, there's two integers separated by a slash. While it's true that there's a leading 0 on the card itself, there's no reason not to just split on the / and convert both sides to integers.
- satokema 8y agoIt depends on the human. Some humans might interpret "01" as one yes, but others will see it as a "zero-one".
- gumby 8y agoyes, but this is what people write when filling out paper forms, showing that they consider 0 suppression the norm.