Eh? That is not something a webpage can do, for all sorts of reasons. HN can only paste what you have copied before, so I'm afraid this is most likely a case of user error.
I agree that this is probably just an error, but I have seen sites that manipulate copies before (usually to add "Read more at URL" or something)
You're right, I didn't explain myself correctly. What I meant to say is that Javascript from one site is forbidden by default from operating on the contents of another site. So if you didn't copy the text from site A in the first place, it is not possible (at a basic security level) for site B code to access the text from site A which never made it into the clipboard.
It would be much more helpful for everyone if you explained where you think I'm incorrect, rather than mindless downvoting. Having worked professionally with Javascript for almost 20 years, I would hate to miss an opportunity to learn something more about it.
Javascript cant edit the clipboard, but it can change the contents of the region youre selecting.
Within the same site, sure. Cross-site, it cannot.
Presumably by "this site" mikek meant the site hosting the article.