Ask HN: Implementing Auto-Copy
I've been scratching my head and Googling the last couple of days looking for a way to implement auto-copy into a project. We've tried using the clipboard implementation which basically uses a small flash file to copy, only problem is that it breaks in Flash 10.
Need some help from the hackers, I'm all out of ideas.
EDIT: I wasn't that clear, sorry. Basically I have a url shortening script and I want someone to be able to shorten a url, be redirected to a page and have that short url they created auto-copied to their clipboard - so they can just close the window and paste the link easily.
http://url.ie (another url shortening service -- do we need yet more???!) does exactly what you want. I believe it's just javascript but you can check the page source for yourself
You would have to somehow get the user to click on the Flash object. I wouldn't rely on Flash for the user experience, though. What YouTube does is probably best (an input box that selects all on click). People are probably most familiar with that method.
Even better would be to figure out a workflow where the user doesn't have to copy, or paste anything.
Auto-Copy as in the firefox extension? Or what?
I think you're going to need to be a bit more specific here.
I like the idea of a popup box and making the cursor ideally select all the text.
oh and could you make your bookmarklet popup in a new window? never got why people didnt do that.