My personal bête noire is sites that misuse type=password for 2FA inputs, since that confuses password managers and browsers both.
There is a way to annotate it. autocomplete=one-time-code https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes...
HTML Form Validation is underused
131–140 of 343 posts
Re: HTML Form Validation is underused
#132Maybe that is user friendly but for sure I don't like to see the backend bombarded with API calls each time an user types a letter.
Re: HTML Form Validation is underused
#133Earlier quoted context omitted.
On Android, the date picker widget is fiddly to use for selecting distant dates, like date of birth. Not impossible but requires many many taps.
That's an implementation issue, not a specification issue. The specification just suggests the user is shown a date picker.
That you’re correctly using html forms won’t quickly lead to browser improvements.. so the result is that users will hate your forms. Users/your customer might possibly even think that you’re to blame, and not $browserVendor.
Re: HTML Form Validation is underused
#134>Imagine a username input that should be valid only if the username is not taken Maybe that is user friendly but for sure I don't like to see the backend bombarded with API calls each time an user types a letter.
The total amount of traffic in both direction is pretty small, and the logic is simple, especially compared to lots of other things your server is typically doing.
Re: HTML Form Validation is underused
#135Earlier quoted context omitted.
I used to write those fancy textboxes that reformatted your input as a phone number as you type, and intercept paste, and all that. But then it turns out that you really do want a free-form text input. Let people paste text in, edit their text freely, then let it validate afterwards. When it validates, then reformat it. For example, text boxes with length limits. These are awful. It messes with your ability to paste…
Nah. Users are too stupid to fix their own inputs in many cases. Seen inputs with zero-width spaces that are invisible which fail validation. User doesn't understand why, complains. Enforcing a character set for certain kinds of inputs is a very good thing.
You could remove the zero-width spaces in validation (for eg a phone number).
Re: HTML Form Validation is underused
#136Earlier quoted context omitted.
Nah. Users are too stupid to fix their own inputs in many cases. Seen inputs with zero-width spaces that are invisible which fail validation. User doesn't understand why, complains. Enforcing a character set for certain kinds of inputs is a very good thing.
Why blame it on the user, instead of fixing it? You could remove the zero-width spaces in validation (for eg a phone number).
Re: HTML Form Validation is underused
#137>Imagine a username input that should be valid only if the username is not taken Maybe that is user friendly but for sure I don't like to see the backend bombarded with API calls each time an user types a letter.
Re: HTML Form Validation is underused
#138Earlier quoted context omitted.
Why blame it on the user, instead of fixing it? You could remove the zero-width spaces in validation (for eg a phone number).
Or, you know, prevent invalid characters from the get-go. Same thing as validation, but done up-front. (But as I said elsewhere, I'm not talking about phone numbers, I'm talking about amounts)
Re: HTML Form Validation is underused
#139The biggest, easiest to implement underutilization is: "Using specific type attribute values, such as "email", "number", or "url"" These can significantly improve user experience on mobile by triggering the optimal keyboard.
Re: HTML Form Validation is underused
#140In an all honest reply, is that the people that writes these specifications, live disconnected from the reality, they don't use the stuff they specify. That stuff works for very simple things, but then when your forms evolve you realise you will be better off just writing the whole thing yourself.