Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> They blatantly ignore standards, the most obvious of which is their treatment of autocomplete=off in forms[1]. They broke the ability to disable autocomplete, and since then have been intentionally breaking workarounds people find to actually turn off autocomplete. This has been a major pain in the butt at work.

My solution to that is simple. I have a microservice that tells my services how to get autocomplete=off automatically. This microservice determines the required values and ids by scraping the search box on google.com every hour, and extracting the values of the tag matching input[name=q].

That way I can fully automate autocomplete=off, and ensure it works.



That is filthy, and I absolutely love it.


Indeed it is, but sometimes it’s necessary. I absolutely only use it for search boxes where I provide custom history for previous entries, and custom suggestions. Without autocomplete=off, these are horrible to use.

And this was the only way I could figure out that would guarantee that it would be disabled, even after browser updates.




Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: