6 ms·
I'm going to side with the Chrome team on this one. There's very few occasions when autocomplete being disabled makes sense, the vast majority are just develope
by Someone1234 10y ago
I'm going to side with the Chrome team on this one. There's very few occasions when autocomplete being disabled makes sense, the vast majority are just developers dumping it in there because they want to make doubly-sure the user actually entered a field by hand (e.g. email addresses) and often for vaporous reasons like "Improve Data Quality," "Stop Spammers/Bots," and "Make sure the user enters the right data in the right box."
Ultimately if you want to assure data quality then use data or format validation, or verification (e.g. send an email with link). If you want to stop bots/spammers use captcha.
We did go through a period where people were "misusing" standard input boxes for other things and autocomplete would ruin that extra usage. But hopefully we've moved beyond turning an input box into a richtextbox using a complex array of hacks, and can now instead use things like Canvas.
PS - Hopefully they disable "smooth scroll" scripts next. So tired of having my scrolling ruined by "helpful" sites.
- mrweasel 10y ago>There's very few occasions when autocomplete being disabled makes sense True, perhaps. The point is that's not for Google to decide. In their example with CRM system, it's very possible that the developer did think about it, and decided that autocompletion would "help" the user enter wrong data. Now Chrome forces you to be non-compliant to work-around to their "custom feature". Chrome is increasingly encouraging developer behaviour that's reminiscent of Microsoft and Internet Explorer 6.
- timdierks 10y agoIt's not for the developer to decide any more than the browser. It's up to the user.
- wmil 10y agoExcept there's no ability for the user to disable autosave on a page specific basis. So if autocomplete breaks functionality then there's nothing the user can do if the developer assumed autocomplete='off' would continue to work. Except disable autocomplete on every site, which is kind of overkill.
- dragonwriter 10y ago> So if autocomplete breaks functionality then there's nothing the user can do if the developer assumed autocomplete='off' would continue to work. Developers should not expect that things specced as hints will be treated as authoritative direction and should not make software that breaks if that unreasonable expectation doesn't hold.
- volatilitish 10y agoThere are lots of examples. I'll give one. A text input for a chat you're having with someone. It's very very offputting and irritating to have the browser constantly cluttering the UI with suggestions about what you might want to type in that chat box before you press enter.
- gmazza 10y agoMessage input field for chat/forum would typically be <textarea>. For example - have a look at reply page source right here, on HN. And <textarea> doesn't auto-complete regardless of explicit options.
- pluma 10y agoChat input is typically single-line, submit-on-enter. Messaging apps seem to be transitioning to optional multiline but the default action for enter still seems to be submit so it's perfectly reasonable to use <input> for chat input.
- tracker1 10y agoWell, inline chat, like IRC is generally a single-line input... though I suppose you could use a textarea rows="1" and strip \n on paste, etc, that wouldn't be too bad as you're likely listening for \n to post the message anyway. Either way, not using a typical name/id for the text input would probably work better in terms of not getting suggestions...
- volatilitish 10y agoThat would indeed be the norm for forums. But not for chat. Real time chat is typically more usually a single line entry. Having auto-complete on that is irritating and utterly spoils the UI.
- gkya 10y ago> There's very few occasions when autocomplete being disabled makes sense What are those (seriously, I can't think of any off the top of my head).
- chillacy 10y agoI know of one from a previous project. We had a prompt that said "enter your home address" with JavaScript autocomplete using google location APIs. Unfortunately chrome would try to auto fill this box with a city name (not even the full address) and this auto fill prompt sat on top of the JS drop down.
- gkya 10y agoWouldn't making it a textarea w/ rows=1 work? AFAIK textarea is not completed.
- kalleboo 10y agoSo we're back to hacks to replicate a feature that browser developers have decided to ignore? Gotta love web technology. If "just use a textarea" is a valid solution, why did Google even bother not honoring autocomplete?
- gkya 10y agoWell, the web technology is a pile of sh.t and in this case with the textarea you don't put your hands as deep in to is as you'd with the text input. That's how I interact with the web technology.
- kalleboo 10y agoIt's just amusing, that's all. Prediction for the future: 1. Google implements auto-complete for one-line textareas 2. Web developers create textareas with 2 lines but hide the bottom line with CSS and disable the return key 3. Something so diabolical even I can't think of it
- tracker1 10y agoThe irony is when I have to hand-enter my email address, especially on my phone, I'm far more likely to mistype it and make a mistake... And on the receiving side, I'm sick of seeing emails for someone else.