how can i stop people from saving my page

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
EXDev
Forum Newbie
Posts: 7
Joined: Sun Feb 23, 2003 9:05 am

how can i stop people from saving my page

Post by EXDev »

Hi,

Anyone know how can i stop people from saving my page? i'm not talking about javascript right click disable, cause people can use save as to download the whole page. i want it like http://www.bn.com (barnes and noble) when people try to save the whole page, it will have an alert message saying "The web page could not be saved to the selected location."

Highly appericated if anyone can help

Thanks
User avatar
Stoker
Forum Regular
Posts: 782
Joined: Thu Jan 23, 2003 9:45 pm
Location: SWNY
Contact:

Post by Stoker »

there is no way of doing that, as the nature of HTML is open and plain text.... and even if you used a javaapplet to decrypt something for view in applet only, there is always someone that will examine your applet and find your algorithms..

btw, barnes and noble did not prevent anything with my mozilla browser..
evilcoder
Forum Contributor
Posts: 345
Joined: Tue Dec 17, 2002 5:37 am
Location: Sydney, Australia

Post by evilcoder »

yep, stopped nothing on konquer either :)
User avatar
patrikG
DevNet Master
Posts: 4235
Joined: Thu Aug 15, 2002 5:53 am
Location: Sussex, UK

Post by patrikG »

IE 5.5 without ServicePack 2 download it as well without problems.
User avatar
twigletmac
Her Royal Site Adminness
Posts: 5371
Joined: Tue Apr 23, 2002 2:21 am
Location: Essex, UK

Post by twigletmac »

If you don't want people to save your page don't put that page on the Internet. There is no way that you can prevent this otherwise.

Mac
pistolfire99
Forum Commoner
Posts: 58
Joined: Thu May 23, 2002 3:18 pm

Post by pistolfire99 »

Try and make all your pages into flash files, this way they have very limited control on what they do, even after they download your page. pdf is another alternative.
My $0.02 .. :)
User avatar
m3mn0n
PHP Evangelist
Posts: 3548
Joined: Tue Aug 13, 2002 3:35 pm
Location: Calgary, Canada

Post by m3mn0n »

Stoker wrote: there is no way of doing that
That's a false statement. I've seen it done on a warez type site. I think it was with java. I e-mailed the owner asking him how but he wouldn't tell me. The rightclicking on the page was disabled along with the Tools > View Source menu and in Netscape it was the same case.

So it is possible but only an elite few know how to do it. :evil:
User avatar
Stoker
Forum Regular
Posts: 782
Joined: Thu Jan 23, 2003 9:45 pm
Location: SWNY
Contact:

Post by Stoker »

As indicated by several others, it is not a false statement, it can't be done... Show us an URL and we'll show you the source (HTML) :)
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Post by volka »

if there really should be no other way (hi, my beloved debugger :twisted: ) then there is still wget :twisted: :twisted:
User avatar
phice
Moderator
Posts: 1416
Joined: Sat Apr 20, 2002 3:14 pm
Location: Dallas, TX
Contact:

Post by phice »

So let's all agree that he can't hide his HTML source, without wasting hours working with Flash or Adobe PDF files to get what he wants.
Image Image
Gen-ik
DevNet Resident
Posts: 1059
Joined: Mon Aug 12, 2002 7:08 pm
Location: London. UK.

Post by Gen-ik »

You can sort of do it...

Use a simple Flash button to launch a pop-up window.

You can trigger JavaScript from Flash.. simply enter JavaScript code instead of linking to a URl..
for example Get URL "javascript:open.window('page.php','','options');"
No one can see the JavaScript you use inside a Flash movie.

The page in the pop-up window needs the Right-Click disabled so in the <head> of your pages add this line of JavaScript....
document.oncontextmenu = new Function("return false");

Don't forget to use the following when opening the pop-up window..
"menubar=no, toolbar=no"


That gives you a 'more' secure site.. but it's not bullet-proof.
Gen-ik
DevNet Resident
Posts: 1059
Joined: Mon Aug 12, 2002 7:08 pm
Location: London. UK.

Post by Gen-ik »

Oromian wrote: That's a false statement. I've seen it done on a warez type site. I think it was with java.
Try and find this 'holy-grail' of websites would you and let us know where it is...... cheers.
Dave
Forum Newbie
Posts: 8
Joined: Mon Jun 17, 2002 3:14 am

Post by Dave »

I've seen this done on a phone logo's site, but I got around it by saving the target page from the page that linked to it.

As said above - if someone really wants what you have on your page, there is always a way and if people are anything like me, the more someone tries to block you, the more you'll try to get around it - generally just to see if you can.
User avatar
phice
Moderator
Posts: 1416
Joined: Sat Apr 20, 2002 3:14 pm
Location: Dallas, TX
Contact:

Post by phice »

If the window pops up in a small window without the address, etc, you can just press [F11] and i'll show the address bar in full-screen mode.
Image Image
Post Reply