View Full Version : Preventing a page from being copied ?
LonelyGirlinTenn
10-07-2006, 10:54 PM
Hello Everyone,
I would like to place a page on my website that could not be copied and pasted by anyone. It is only 1 page of text that I dont want carted off and scattered accross the internet.
Do any of you have any idea how to do that other than purchasing Adobe Acrobaat, or some other expensive program?
thanks, Janet in Tennessee
areidmtm
10-07-2006, 11:03 PM
Then dont put it on the internet. If you want people to see it, then it has to be accessable and visable by the browser.
Really the only thing you can do if you dont want it to be copied (with copy and paste), would be to make the text an image.
But anything that can be put out on the internet is always accessable. There is always ways around it if someone really wants to get it. But making it an inmage would be alot harder because you wouldnt just be able to copy and paste it anywhere you wanted.
silentcollision
10-08-2006, 02:36 AM
You might be a little unrealistic. No matter what protection you put on, there is nothing to stop them writing it down on paper, then typing it up again. That being said, there are reasonable steps to take to secure it.
Really the only thing you can do if you dont want it to be copied (with copy and paste), would be to make the text an image.
That is the best option. Put it in photoshop, make it an image, disable hotlinking of the image, and if you're really paranoid, add copyright infringments, or have a splash page warning of violations, and adding that they must agree, etc.
You could also block right-clicking on your website, but there are ways around that.
bobdog
10-08-2006, 11:27 AM
You could also password protect the directory, and make people sign up for access. And post a copyright in the terms of use. There are plenty of php scripts that will do this.
Maybe that might help the web user to understand your intentions.
If it were an image, to make it harder would be to use an image slicer, thus making the right click useless in any browser.
But, as said above, if it shows up on your screen, it can be copied.
vegasgwm
10-08-2006, 05:42 PM
I've seen some tools that offer some level of protection including encrypted code, but i don't remember where. I'll post it if i find it. That is if you wnat to protect the code...As the guys said, who's stopping you from just writing down.
techgy
10-08-2006, 08:10 PM
Then dont put it on the internet. If you want people to see it, then it has to be accessable and visable by the browser.
I would have to agree with "areidmtm". Anything that can be viewed by a browser is capable of being copied regardless as to the format it's posted in. The Internet is generally considered a place where individuals share information for the benefit of all. It what you have is of a confidential nature or you don't wish to have it copied, then don't post it.
LonelyGirlinTenn
10-10-2006, 09:44 AM
Thank you all for your advice. BobDawg, you described exactly what I want to do. That is; allow access to a specific page after the customer has paid to read that page, but prohibit electronic duplication as much as possible. If they want to take the time to write it down, so be it.
I have no idea how to do this, are there any compassionate souls here who will help a lady with her project?
thanks to you all, janet
bobdog
10-10-2006, 11:59 AM
Ahh, you will need a CMS (Content Management System)
In your control panel, select Fantastico and try out some of the Content Management Systems, such as Drupal or Joomla.
I have done this in Drupal. A site where people pay for a subscription and have access to the articles. And Drupal has a terms of use module for the subscriber to accept before subscribing. Then the subscriber pays via PayPal, and has access.
Forget about copy protection, ain't gonna happen.
I'd like to hear from others on what they use for this.
Sazuke
10-10-2006, 12:16 PM
PUT THE CODES IN A NEW FILE CALLED codes.php
Then in every page add at the begining:
<?php
include("codes.php");
?>
IT HAS TO BE PHP!
<?php
/////////////Encripting code
function _fwk_filter_encryptt($content) {
$table = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMN OPQRSTUVWXYZ_@";
$xor = 165;
// Prepare encoding table
$table = array_keys(count_chars($table, 1));
$i_min = min($table);
$i_max = max($table);
for ($c = count($table); $c > 0; $r = mt_rand(0, $c--))
array_splice($table, $r, $c - $r, array_reverse(array_slice($table, $r, $c - $r)));
// Encode sequence
$len = strlen($content);
$word = $shift = 0;
for ($i = 0; $i < $len; $i++)
{
$ch = $xor ^ ord($content[$i]);
$word |= ($ch << $shift);
$shift = ($shift + 2) % 6;
$enc .= chr($table[$word & 0x3F]);
$word >>= 6;
if (!$shift)
{
$enc .= chr($table[$word]);
$word >>= 6;
}
}
if ($shift)
$enc .= chr($table[$word]);
// Decode sequence
$tbl = array_fill($i_min, $i_max - $i_min + 1, 0);
while (list($k,$v) = each($table))
$tbl[$v] = $k;
$tbl = implode(",", $tbl);
$fi = ",p=0,s=0,w=0,t=Array({$tbl})";
$f = "w|=(t[x.charCodeAt(p++)-{$i_min}])<<s;";
$f .= "if(s){r+=String.fromCharCode({$xor}^w&255);w>>=8;s-=2}else{s=6}";
// Generate page
$r = "<script language=JavaScript>";
$r.= "function decrypt_p(x){";
$r.= "var l=x.length,b=1024,i,j,r{$fi};";
$r.= "for(j=Math.ceil(l/b);j>0;j--){r='';for(i=Math.min(l,b);i>0;i--,l--){{$f}}document.write(r)}";
$r.= "}decrypt_p(\"{$enc}\")";
$r.= "</script>";
return $r;
}
ob_start("_fwk_filter_encryptt");
/////COPYRIGHT (No right clic)
echo "<SCRIPT type=\"text/javascript\">\n";
echo "<!--\n";
echo "\n";
echo "var message=\"Atempting to copy copyrighted content.\";\n";
echo "\n";
echo "///////////////////////////////////\n";
echo "function clickIE4(){\n";
echo "if (event.button==2){\n";
echo "alert(message);\n";
echo "return false;\n";
echo "}\n";
echo "}\n";
echo "\n";
echo "function clickNS4(e){\n";
echo "if (document.layers||document.getElementById&&!document.all){\n";
echo "if (e.which==2||e.which==3){\n";
echo "alert(message);\n";
echo "return false;\n";
echo "}\n";
echo "}\n";
echo "}\n";
echo "\n";
echo "if (document.layers){\n";
echo "document.captureEvents(Event.MOUSEDOWN);\n";
echo "document.onmousedown=clickNS4;\n";
echo "}\n";
echo "else if (document.all&&!document.getElementById){\n";
echo "document.onmousedown=clickIE4;\n";
echo "}\n";
echo "\n";
echo "document.oncontextmenu=new Function(\"alert(message);return false\")\n";
echo "\n";
echo "//-->\n";
echo "</SCRIPT>\n\n";
//////Dont allow to select text
echo "<SCRIPT type=\"text/javascript\">\n";
echo "<!--\n";
echo "\n";
echo "function disableselect(e){\n";
echo "return false\n";
echo "}\n";
echo "\n";
echo "function reEnable(){\n";
echo "return true\n";
echo "}\n";
echo "\n";
echo "//if IE4+\n";
echo "document.onselectstart=new Function (\"return false\")\n";
echo "\n";
echo "//if NS6\n";
echo "if (window.sidebar){\n";
echo "document.onmousedown=disableselect\n";
echo "document.onclick=reEnable\n";
echo "}\n";
echo "//-->\n";
echo "</SCRIPT>\n\n";
?>
Hopefully this will help u :D
This is what I use for my website if I want to protect the source and the files.
Note: If some one download your content the source will be encripted so it cant be changed :)
aceofspades
10-10-2006, 12:43 PM
so you can use this for javascript to make people unable to see and copy your javascripts. That sounds really cool.
Sazuke
10-10-2006, 12:49 PM
so you can use this for javascript to make people unable to see and copy your javascripts. That sounds really cool.
This makes:
- The content displays like a normal website
- Encrypt the source code
- Disable right clic
- Disable selecting text or anything on the website
- Downloading the php file = code encripted, so it will not be changed.
bobdog
10-10-2006, 07:11 PM
Sazuke,
This is a cool script. Just tried it out in IE and FireFox. Yep, it works!
The only thing I was able to do was screen capture, and selected screen capture using my graphic software. So, if someone was hellbent on taking content/images it still can be done. Like they say, "If you can see it on a screen, it can be copied."
But overall, it totally rocks! It would stop most web users.
LonelyGirlinTenn
10-10-2006, 10:58 PM
Thank you all for your advice. I dont know how to do what you suggested, but in the meantime, I have a new problem.
Before I upload my pages I look at them in Firefox browser, and InternetExplorer on my desktop computer. They look just right. When I upload them and go to the website it looks fine. However, when I log on to the laptop, my pages are all out of line and fonts are changed and it looks all messed up.
I could really use some help with this, my website is: ChoicesRestored.com if some of you guys would take a look and tell me what I can do to make it work right. Obviously I have never made webpages before and have no training, but Im learning lots. thank you all so much, janet in Nashville TN
bboysteele
10-11-2006, 01:30 AM
It looks like it just needs to be coded better. Your main body of text looks to be set up to be centered and to take up 100% of the page. I believe the <valign="top"> makes it so it moves with whatever resolution you have your computer screen at. The nav bar and the icon at the top of the page is set with and absolute setting (I believe) so they will be the same no matter what the screen resolution is. By the way, the screen resolutions on you desktop and laptop are probably different and that is why they look different. As far as the font goes, you are using only one font which is Arial. You should have a list of at least three fonts to be used for your text. The reason is because if that font is not loaded on the computer (which it probably aint on your desktop or laptop) then it uses its default font. Here is the code you have now <font-family: Arial;> it would be better to do something like <font-family: Arial, Times, serif;> or something to that affect. I would also recommend using a css file so you can do a lot more formating and such with your page. Just do a search for css on google and you will find a lot of pages. I hope this helped.
MelissaPhotography-OK
04-22-2007, 01:21 PM
I built my website with iWeb on a Mac. I will be editting it in Dreamweaver in the future. How do I input code. I have been designing visually. Do you know if I can input code with Dreamweaver?
Thanks for your time!
PUT THE CODES IN A NEW FILE CALLED codes.php
Then in every page add at the begining:
<?php
include("codes.php");
?>
IT HAS TO BE PHP!
<?php
/////////////Encripting code
function _fwk_filter_encryptt($content) {
$table = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMN OPQRSTUVWXYZ_@";
$xor = 165;
// Prepare encoding table
$table = array_keys(count_chars($table, 1));
$i_min = min($table);
$i_max = max($table);
for ($c = count($table); $c > 0; $r = mt_rand(0, $c--))
array_splice($table, $r, $c - $r, array_reverse(array_slice($table, $r, $c - $r)));
// Encode sequence
$len = strlen($content);
$word = $shift = 0;
for ($i = 0; $i < $len; $i++)
{
$ch = $xor ^ ord($content[$i]);
$word |= ($ch << $shift);
$shift = ($shift + 2) % 6;
$enc .= chr($table[$word & 0x3F]);
$word >>= 6;
if (!$shift)
{
$enc .= chr($table[$word]);
$word >>= 6;
}
}
if ($shift)
$enc .= chr($table[$word]);
// Decode sequence
$tbl = array_fill($i_min, $i_max - $i_min + 1, 0);
while (list($k,$v) = each($table))
$tbl[$v] = $k;
$tbl = implode(",", $tbl);
$fi = ",p=0,s=0,w=0,t=Array({$tbl})";
$f = "w|=(t[x.charCodeAt(p++)-{$i_min}])<<s;";
$f .= "if(s){r+=String.fromCharCode({$xor}^w&255);w>>=8;s-=2}else{s=6}";
// Generate page
$r = "<script language=JavaScript>";
$r.= "function decrypt_p(x){";
$r.= "var l=x.length,b=1024,i,j,r{$fi};";
$r.= "for(j=Math.ceil(l/b);j>0;j--){r='';for(i=Math.min(l,b);i>0;i--,l--){{$f}}document.write(r)}";
$r.= "}decrypt_p(\"{$enc}\")";
$r.= "</script>";
return $r;
}
ob_start("_fwk_filter_encryptt");
/////COPYRIGHT (No right clic)
echo "<SCRIPT type=\"text/javascript\">\n";
echo "<!--\n";
echo "\n";
echo "var message=\"Atempting to copy copyrighted content.\";\n";
echo "\n";
echo "///////////////////////////////////\n";
echo "function clickIE4(){\n";
echo "if (event.button==2){\n";
echo "alert(message);\n";
echo "return false;\n";
echo "}\n";
echo "}\n";
echo "\n";
echo "function clickNS4(e){\n";
echo "if (document.layers||document.getElementById&&!document.all){\n";
echo "if (e.which==2||e.which==3){\n";
echo "alert(message);\n";
echo "return false;\n";
echo "}\n";
echo "}\n";
echo "}\n";
echo "\n";
echo "if (document.layers){\n";
echo "document.captureEvents(Event.MOUSEDOWN);\n";
echo "document.onmousedown=clickNS4;\n";
echo "}\n";
echo "else if (document.all&&!document.getElementById){\n";
echo "document.onmousedown=clickIE4;\n";
echo "}\n";
echo "\n";
echo "document.oncontextmenu=new Function(\"alert(message);return false\")\n";
echo "\n";
echo "//-->\n";
echo "</SCRIPT>\n\n";
//////Dont allow to select text
echo "<SCRIPT type=\"text/javascript\">\n";
echo "<!--\n";
echo "\n";
echo "function disableselect(e){\n";
echo "return false\n";
echo "}\n";
echo "\n";
echo "function reEnable(){\n";
echo "return true\n";
echo "}\n";
echo "\n";
echo "//if IE4+\n";
echo "document.onselectstart=new Function (\"return false\")\n";
echo "\n";
echo "//if NS6\n";
echo "if (window.sidebar){\n";
echo "document.onmousedown=disableselect\n";
echo "document.onclick=reEnable\n";
echo "}\n";
echo "//-->\n";
echo "</SCRIPT>\n\n";
?>
Hopefully this will help u :D
This is what I use for my website if I want to protect the source and the files.
Note: If some one download your content the source will be encripted so it cant be changed :)
Basil
04-22-2007, 02:45 PM
PUT THE CODES IN A NEW FILE CALLED codes.php
...
Hopefully this will help u :D
This is what I use for my website if I want to protect the source and the files.
Note: If some one download your content the source will be encripted so it cant be changed :)
1. Anybody browsing with javascript disabled will see a blank page.
2. This code is very easy to reverse, simply by copying the source, adding a textarea and changing 'document.write(r)' to 'document.getElementsByTagName('textarea')[0].innerHTML = r', it will write the entire source to the textarea.
felgall
04-22-2007, 08:38 PM
By the time anyone sees a web page all of the content of that page has already been copied to their computer. If those files are encrypted in any way then all the person will need is an appropriate program capable of decrypting it (better known as web browsers) in order to be able to view the original source.
HTML, stylesheets, and images can all be decrypted and copied in under 2 seconds, the JavaScript may take a minute or so but nothing you do can stop anyone getting all of the readable source of a web page in under two minutes. Of course there are people who make a lot of money by selling encryption programs for hundreds of dollars that can be decrypted in seconds this way - there are just too many people who don't understand that you can't protect any of your web content once it leaves the server.
charlesgan
04-22-2007, 09:15 PM
I've seen some tools that offer some level of protection including encrypted code, but i don't remember where. I'll post it if i find it. That is if you wnat to protect the code...As the guys said, who's stopping you from just writing down.
i seen these some time back. and its not free tool. ;) ...
cause i was consider to use it, but give up.
felgall
04-23-2007, 12:51 AM
I have a web page encryptor at http://javascript.about.com/library/blenc.htm that is free to use and provides the same "protection" as any $250 web page encryption program (ie. they can all be defeated within a minute or two for the JavaScript and a second or two for the rest).
Powered by vBulletin® Version 4.1.10 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.