Hacker News new | ask | show | jobs
by moonlighter 1093 days ago
Another nuisance which really gets on my nerves is when sites specifically prevent me from pasting, typically fields where you need to put a bank account or routing number. Copy and pasting that info is WAY more accurate and error-proof than glancing at one screen and re-typing it in another. I then temporarily disable Javascript in the developer menu and re-enabled it afterwards, but that still sometimes causes issues down the line, as now the site "thinks" there isn't a value in the field because they didn't notice any typing events, etc..
3 comments

It's easier to ctrl-shift-c to pick the element in the inspector, then paste into the value="" HTML in the developer tools.

Also useful on treasurydirect.gov which has a ridiculous password entry field. They make an on-screen "keyboard" with a bunch of JS buttons, you have to click those buttons to enter your password. You can't type into the password field or paste into it.

When I saw that treasury login form with the onscreen keyboard you had to click, I was absolutely flabbergasted. Thankfully they've now done away with it.
usually it isn't necessary to disable all JS, but right-click and inspect will show the text input has an attribute like `onPaste="() => return false"` which can just be changed to true instead. or just remove the attribute. I'm on my phone so the syntax may be slightly wrong but that's the gist.
>It's easier to ctrl-shift-c to pick the element in the inspector, then paste into the value="" HTML in the developer tools.

I use "Happy Right-Click" firefox addon for this. Just click the addon icon located on the address bar and voila.

In France a lot of bank websites have this on screen keyboard.

I assumed it's against keyloggers.

While I don’t agree with the implementation, I think this is usually done on forms that ask you to confirm the value a second time. The goal is not to prevent you from pasting from an accurate source; instead they are trying to prevent users from copying an incorrectly manually typed value from one field to the other. The end result just also blocks our use case…
sometimes websites forget to disable selection dragging, so you can paste in the first field and drag to the second field.
Install Don't Fuck with Paste. Thankfully I don't have to use it that often anymore so it stays hidden in the overflow section most of the time, but it's so useful when I need it.