# Block Web copy,paste and page print



## frankv (Jul 15, 2005)

Can anyone help me with HTML code or java Script to stop web-page printing or scramble the print when they click a print button? I have found disable cut, copy, paste but I would like to disable web-page printing..
thanks


----------



## Big-K (Nov 22, 2003)

Why? If you want to prevent people from taking the text it's useless. No matter what you do you can't prevent people from taking text or graphics from a site.


----------



## drdrew1469 (Nov 30, 2000)

sorry, even if you coded the most miraculous page, people can still 'alt-print screen' for graphics. did you also disable 'right-click as well to hide your code? it's still viewable through 'View source' just so you know. if you don't want people to get your content, don't put it on the web...lol, that sounds funny but it's true.

hth,

drew


----------



## frankv (Jul 15, 2005)

Big-K said:


> Why? If you want to prevent people from taking the text it's useless. No matter what you do you can't prevent people from taking text or graphics from a site.


My intent was to make it difficult for people to print certain pages from our site. Right to easy to click file print and then distribute. Even if I can make this difficult it is worthwhile..

fpc


----------



## drdrew1469 (Nov 30, 2000)

well, you're talking a few things here. javascript - alot of people turn it off. activex controls maybe - [shudders], controlling a client side application...wow. lol, i have ethical dilemmas with this whole thing  i can't even think off the top of my head if this is even possible, sure you can slow them down, but 'stop completely' - i don't know about that.

drew


----------



## southernlady (May 6, 2004)

You can watermark your graphics and that makes them almost useless to the person *stealing* them but that is about the only thing you can do that is worthwhile ad far as helping yourself. That and placing a copywrite on your web site and then filing it. But that takes time and money. And you have to prove you have the legal right to it's ownership. Liz


----------



## erick295 (Mar 27, 2005)

You don't have to file for a copyright if you don't want to - if you create something, it's copyrighted by default.

I personally get very annoyed when I run accross sites that block right-clicking and other browser features. Since they're all easy to get around, it just causes problems for your users, and does very little to help you. I always kind of laugh when I right click on a site only to read "OUR IMAGES CANNOT BE COPIED!!" or something to that effect, apparently written by someone who has no idea what Print Screen does.

My question is, if you do not want people to be able to keep your content, why are you putting it online?


----------



## frankv (Jul 15, 2005)

My website is primarily because of a Political battle between myself and the Mayor of the town I work for. I have articles and information about him and some ridiculous things he does. He prints my web pages, and distributes them to people on the street and of course writes his own comments all over them and skews what was actually written. The purpose to block this is more to be a pain to him than to anyone else. 

He actually is doing me a favor by distributing its just to easy for him to highlight lines and write in his own rebuttal.

That's the purpose. It is on the web for everyone to read. Too convenient for him rather than having to write down what he is reading...

thanks for the response


----------



## Rockn (Jul 29, 2001)

What's the problem then? If he is that childish to re-write or change the meaning or context of things you have typed, that makes him look all the more the fool. You could fool him by adding a "printer friendly" version that is misspelled or could have some other content entirely different. That may however alienate any readers that may actually want to read it. 

Sounds like a personal issue between you two.


----------



## arcadianz (Aug 5, 2005)

I have a couple of websites that I need to block content in and so the best way I found to do this was to use a software program which encrypts the webpage. There are many programs out there that do this type of thing but the one I use is called Webpro4. Here is the speal from their website:

_WebCrypt PRO, the first in our suite of HTML Utilities, successfully encrypts ANY html page, including javascript. Foil spam spiders looking for e-mail targets, protect your graphics from being swiped, stop your pages from being saved, printed, or copied, and more. Our exciting new Image-Splicer gives your graphics even more protection, by splicing your images into smaller files. Visitors to your site will see your images exactly as intended - but your originals stay tucked away safely in your possession - where they should be._
The cost is $39.95, but well worth it.

How ever it won't stop the Alt+Print Screen

Hope this helps


----------



## arcadianz (Aug 5, 2005)

I have a couple of websites that I need to block content in and so the best way I found to do this was to use a software program which encrypts the webpage. There are many programs out there that do this type of thing but the one I use is called Webpro4. Here is the speal from their website:

_WebCrypt PRO, the first in our suite of HTML Utilities, successfully encrypts ANY html page, including javascript. Foil spam spiders looking for e-mail targets, protect your graphics from being swiped, stop your pages from being saved, printed, or copied, and more. Our exciting new Image-Splicer gives your graphics even more protection, by splicing your images into smaller files. Visitors to your site will see your images exactly as intended - but your originals stay tucked away safely in your possession - where they should be._
The cost is $39.95, but well worth it.
The website: http://www.moonlight-software.com/

How ever it won't stop the Alt+Print Screen

Hope this helps


----------



## brendandonhu (Jul 8, 2002)

That's a joke...anyone can get around that in 30 seconds.


----------



## arcadianz (Aug 5, 2005)

Perhaps a person with a good knowledge could but definately not anyone! and definately not in 30 seconds. Have you used this software? If not then you aren't familiar with all it's functions. Anyway it works well enough for me and is ideal for most people. The bottom line is anything can be taken off the web if a person is determined enough.

The only way I have found to save an image is through Screen Capture; so to protect images you can watermark them, which is what I've done.


----------



## brendandonhu (Jul 8, 2002)

That companies website is full of lies. They claim the source code is "encrypted", its NOT encrypted at all, there is no encryption done.
All it does is add this poorly written script to your code

```
<SCRIPT LANGUAGE="Javascript">
document.oncontextmenu = disableRightClick;
function disableRightClick()
{
 return false;
}
var message=""
function click(e)
{
if (navigator.appName == "Netscape" &&
(e.which == 3 || e.which == 2))
return false;if (document.all)
{
if (event.button == 3)
{
return false;
}
if (event.button == 2)
{
return false;
}
}if (document.layers)
{
if (e.which == 3)
{
return false;
}
}
}
if (document.layers)
{
document.captureEvents(Event.MOUSEDOWN);
document.captureEvents(Event.MOUSEUP);
}
document.onmousedown=click
document.onmouseup=click
</script><style Media="Print" type="text/css">
body {display:none}
</style>
```
Then encode your HTML in hexadecimal. The ONLY way it "hides" your source is by replacing the letter "a" with "%61", the letter "b" with "%62", etc.

You could save $39.95 by adding that script to your page, then running your source through this: http://centricle.com/tools/ascii-hex/

It takes no skill or knowledge to get the source of one of those pages, all you have to do is copy and paste its source code into this form:
http://centricle.com/tools/ascii-hex/

5 seconds later, you have the source.


----------



## JohnWill (Oct 19, 2002)

It does seem pretty lame, if they encoded their page with this product, it was a dismal failure.


----------



## brendandonhu (Jul 8, 2002)

It is very lame. It bothers me that the company in question claims to "encrypt" the code, but there is no "encrpytion" done. This program fails to do anything except 1) Make the page break on old browsers 2) Completely block blind people from using the website.

And $40 for software to do something I can do by hand in less than a minute?


----------



## namenotfound (Apr 30, 2005)

If anyone buys that software, they should sue the company for not doing what they promised the software would do.


----------



## arcadianz (Aug 5, 2005)

Thanks for explaining further about this software; it seems that I have been sucked in to their blurb. I use a js file linked to each html page which contains all of the information of that page. I will have to rethink my naming of the js files to make them harder to find. 

Is there any (easy) method that anyone can use to reveal all of the files contained on a given website or directory? 

I imagine that there is someway of seeing this info and if so there is little point renaming the js files.

Thanks for sharing your knowledge.


----------



## brendandonhu (Jul 8, 2002)

If their browser can see it, it can be copied very easily.


----------



## namenotfound (Apr 30, 2005)

The only code you can hide from view is server-side code. Because it's processed _before_ it gets to the browser.


----------

