Forum Moderators: open

Message Too Old, No Replies

Disable cut and paste?

         

The Literary Thug

6:35 am on Jul 29, 2003 (gmt 0)

10+ Year Member



Is there a way to keep readers from copying your original material? I know they can still get it from the source code, but I'd like to entice the casual surfer to send the link to friends instead of copying and pasting (and leaving off the copyright/url information:P).

Thanks everyone.

Jenstar

6:48 am on Jul 29, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



There is not a lot you can do, while still keeping your site user-friendly. The options I can think of:

Using PDF files (which should be avoided unless absolutely needed.)

Putting your text into an image file.

Using CSS with a transparent image overlay. I think this option works, but I have never used it to protect text myself, so I could be wrong. I do know it works for preventing people from right clicking on an image to save it (they end up saving the transparent image only). There are some pretty knowlegable members in the CSS forum that can help you with this. But someone could still view source and get the html version of the text that way.

But all in all, if you put it on the web, someone is capable of stealing it. Have you made it easy for people to send your content to others, such as through a "mail this article to a friend" at the bottom of each one? If you make it easy for people to pass it along to others, it is less likely to end up copied-and-pasted without your copyright/contact info.

tedster

7:12 am on Jul 29, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Try this for your body tag:

<body ondragstart="return false" onselectstart="return false">

I think it only works on IE, and even then, just turning off JavaScript defeats it. But as you said, you only want to deter the casual use of copy paste - and a serious thief can always get your copy.

Jenstar

8:06 am on Jul 29, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Thank you tedster! I wasn't aware of this body tag, and I have already added it to the pages that tend to be "borrowed" the most. Works like a charm ;)

MonkeeSage

2:43 am on Aug 4, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You could also do it like this on the individual elements to make it a little harder to disable:

<p id="protectedText"
onselectstart="return false;"
onclick="return false;"
onmousedown="return false;"
onfocus="return false;">
This is some text that you cannot hilite.
</p>

But as tedster indicated they can always just disable javascript altogether (or for that matter view the source) and then hilite whatever they want.

A couple other solutions that only work in NN / Moz. right now:

Set a rule using the :active pseudo-selector.

#protectedText:active {
display: none;
}

It makes it a little hard to select the text if it disappears when you try! ;)

Or you could alternately use Mozilla's pseudo-properties.

#protectedText {
-moz-user-focus: ignore;
-moz-user-input: disabled;
-moz-user-select: none;
}

Ps. The CSS3 draft has a 'user-select' property that is equivalent to '-moz-user-select'

But even at this, a nice view-source: will let one select and copy as much as they wish to.

Jordan

The Literary Thug

8:57 am on Aug 4, 2003 (gmt 0)

10+ Year Member



thanks for the helpful suggestions, everyone;)

DrDoc

2:50 pm on Aug 4, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



As a side note...

Using PDF files does not disable copying at all.

tschild

3:07 pm on Aug 4, 2003 (gmt 0)

10+ Year Member



Using PDF files does not disable copying at all.

Unless you set "disable printing" and "disable copying" in the Acrobat security options when generating the PDF.

bcolflesh

3:14 pm on Aug 4, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Nope - not even then:

www.ecn.purdue.edu/~laird/PDF/

rahmuss

10:08 pm on Aug 4, 2003 (gmt 0)

10+ Year Member



There are some sites that even viewing the source it shows up all white so you can't read it. I tried copying and pasting it to notepad and MS word, and they won't let you change the color. Any thoughts on how this was done?

MonkeeSage

11:28 pm on Aug 4, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



rahmuss:

The actual source should start somewhere about 1-2 pages after the white space, and will usually be indented by about a page or more. You got to scroll down and then right a ways before you can see it. Sneaky, eh? :)

Jordan

Ryan8720

3:05 am on Aug 5, 2003 (gmt 0)

10+ Year Member



Those aren't attributes of the BODY tag, they are JavaScript events, and can be added to any tag.