1

is there a way to add some sort of copyright message to copied text on a website? For example if somebody copies text via ctrl+c or right click+copy? I once saw this in a website...the reader copied some text and once it was pasted somewhere, it had an additional copyright message attached.

Ideas?

Thanks :)

grady
  • 11,053
  • 26
  • 67
  • 107
  • Not really a good answer, but Huffington Post uses [this](http://www.huffingtonpost.com/include/lib/copy_paste.js) script. I am not sure about compatibility or implementation, but it's worth checking out. – bricker Oct 10 '11 at 09:46
  • 1
    you need to intercept ctrl+c in your javascript. refer to the question [How to detect ctrl+v ,Ctrl+c using Javascript?](http://stackoverflow.com/questions/2903991/how-to-detect-ctrlv-ctrlc-using-javascript) you will find the some useful script – footy Oct 10 '11 at 09:46
  • What about right click with the mouse? – grady Oct 10 '11 at 09:47
  • 1
    The website you saw it on was probably using this: http://www.tynt.com/. Of course, you can do the same thing without using that service. – thirtydot Oct 10 '11 at 09:49
  • @bricker: This did the trick, thanks! The tynt tool does not block mouse copying :) ... its not safe for people who know how to get things in all ways, but a bit safer :). Thanks guys! – grady Oct 10 '11 at 10:39

1 Answers1

2

As @thirtydot pointed out, its good to use a service like http://www.tynt.com/ which removes the headache of scripting for you for intercepting copy+paste

Or refer to the following question How to detect right mouse click + paste using JavaScript? on stackoverflow.

Community
  • 1
  • 1
footy
  • 5,403
  • 12
  • 45
  • 95