Author Topic: Right-Click protection and F10 button (important)  (Read 12131 times)

0 Members and 1 Guest are viewing this topic.

Offline The Sailor

  • Jr. Member
  • **
  • Posts: 84
    • View Profile
Right-Click protection and F10 button (important)
« on: October 27, 2002, 10:57:13 AM »
i find a simple javascript and i think its more useful that the javascript
in header.html becuase when you click (F10) you well disable the Right-Click
protection and you can save any image by Right-Click.
but with this you can not do that.

Please try it to be sure

go to template=>defualt => header.html

Find this code :
Quote

<script language="javascript" type="text/javascript">
<!--
  function opendetailwindow() {
    window.open('','detailwindow','toolbar=no,scrollbars=yes,resizable=no,width=680,height=480');
  }
 
  function right(e) {
    if (navigator.appName == 'Netscape' && (e.which == 2 || e.which == 3)) {
      alert("© Copyright by {site_name}");
      return false;
    }
    else if (navigator.appName == 'Microsoft Internet Explorer' && (event.button==2 || event.button == 3)) {
      alert("© Copyright by {site_name}");
      return false;
    }
    return true;
  }
  document.onmousedown=right;
  if (document.layers) window.captureEvents(Event.MOUSEDOWN);
  window.onmousedown=right;
// -->
</script>

Replace it with this :
Quote

<script language=JavaScript>
var message="© Copyright by {site_name}";
function clickIE4(){
if (event.button==2){
alert(message);
return false;
}
}
function clickNS4(e){
if (document.layers||document.getElementById&&!document.all){
if (e.which==2||e.which==3){
alert(message);
return false;
}
}
}
if (document.layers){
document.captureEvents(Event.MOUSEDOWN);
document.onmousedown=clickNS4;
}
else if (document.all&&!document.getElementById){
document.onmousedown=clickIE4;
}
document.oncontextmenu=new Function("alert(message);return false")
// -->
</script>
(^_^)

Offline The Sailor

  • Jr. Member
  • **
  • Posts: 84
    • View Profile
Right-Click protection and F10 button (important)
« Reply #1 on: October 28, 2002, 10:46:02 AM »
did i do any mistake in all that ? i did't see any comment's :?:
(^_^)

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Right-Click protection and F10 button (important)
« Reply #2 on: October 28, 2002, 01:36:19 PM »
thx alot! it works! :D
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline pietg

  • Jr. Member
  • **
  • Posts: 86
    • View Profile
    • http://www.totaaldigitaal.nl
Right-Click protection and F10 button (important)
« Reply #3 on: November 18, 2002, 10:07:00 PM »
Thank you, just what I was looking for.

Piet
www.totaaldigitaal.nl

Offline zipper

  • Newbie
  • *
  • Posts: 11
    • View Profile
There is another all too easy way.
« Reply #4 on: November 19, 2002, 09:36:27 PM »
I found it by mistake. So i guess other people have don the same thing.

I klick the right mouse button and the alert comes up. I press enter and at the same time press the right mouse button again.
It might not work the first time but it is quite easy to get the "save picture" menu up that way if you try it a couple of times.

I hope i did not spoil anything with this little "guide". :oops:
If I did, Please remove this post so that no one can see how it´s done.

/ Zipper

Offline Chris

  • 4images Moderator
  • 4images Guru
  • *****
  • Posts: 4.487
  • Did u ever stop to think and then forget to start?
    • View Profile
Re: There is another all too easy way.
« Reply #5 on: November 20, 2002, 01:05:37 PM »
Quote from: zipper
I hope i did not spoil anything with this little "guide". :oops:
If I did, Please remove this post so that no one can see how it´s done.

No way!  It's best to leave that kind of info here.  I mean the majority of people in these forums have got to be 4images users, not people who are browsing a site using 4images.  Therefore I think most people would want to know.

Offline zipper

  • Newbie
  • *
  • Posts: 11
    • View Profile
Ok, Good
« Reply #6 on: November 20, 2002, 01:12:57 PM »
Guess you are right abiut that vivid.

Has anyone tested is since i posted this?
I´d like to know if it is just me, Then i should probably reinstall mu browser or something.  :?

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Right-Click protection and F10 button (important)
« Reply #7 on: November 20, 2002, 06:28:33 PM »
zipper, I tryed on my site with [EDITED]Sailors[/EDITED] code...was clicking for 5 min. nothign cameup instead of warnign.
I could explain if that could happend on slow computers..I probably wrong though.

[EDITED]
zipper, as I can see u have another post about uploading bigger images then it's restricted...maybe something wrong with your computer? it's just going through any restrictions, any barriers...hehe, just kidding.
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline zipper

  • Newbie
  • *
  • Posts: 11
    • View Profile
Good one :)
« Reply #8 on: November 20, 2002, 09:21:56 PM »
Hehe, you are probably right.

I´ll look in to the alert problem by trying it on faster computers.
( Mine is a 1,6 Ghz P4 by the way. )

And the code posted above is not mine, it´s The Sailors.
 :wink:

Offline fanncy pants

  • Newbie
  • *
  • Posts: 38
    • View Profile
    • http://www.backshots.us
Internet Explorer's Image Toolbar
« Reply #9 on: November 30, 2002, 11:58:25 PM »
Thanks for the script!  Just what I was looking for.  :)

I'm curious, though, is there anyway to disable all visitors who visit your gallery using Internet Explorer's latest browser, from using IE's Image Toolbar?  If you're not familiar with what this is, the image toolbar in IE browsers appear when you point to an image on a Web page.  The image toolbar makes it easy for you to save, print, or send in e-mail images that you find on the Web.  It would be nice if there was a code to disable this.

I was just wondering if there was a way to disable that by adding a code to one of the gallery's scripts.  If not, I assume using .HTACCESS will be a better route?

Fanncy Pants!

[/color]

Offline Chris

  • 4images Moderator
  • 4images Guru
  • *****
  • Posts: 4.487
  • Did u ever stop to think and then forget to start?
    • View Profile
Yes
« Reply #10 on: December 01, 2002, 12:43:25 AM »
Put this line in the <head> section of header.html
Code: [Select]
<meta http-equiv="imagetoolbar" content="no" />

Offline fanncy pants

  • Newbie
  • *
  • Posts: 38
    • View Profile
    • http://www.backshots.us
Re: Yes
« Reply #11 on: December 01, 2002, 12:44:40 AM »
:D THANKS A LOT!

Fanncy Pants!

[/color]

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)