4images Forum & Community

4images Issues / Ausgaben => Discussion & Troubleshooting => Topic started by: The Sailor on October 27, 2002, 10:57:13 AM

Title: Right-Click protection and F10 button (important)
Post by: The Sailor 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>
Title: Right-Click protection and F10 button (important)
Post by: The Sailor on October 28, 2002, 10:46:02 AM
did i do any mistake in all that ? i did't see any comment's :?:
Title: Right-Click protection and F10 button (important)
Post by: V@no on October 28, 2002, 01:36:19 PM
thx alot! it works! :D
Title: Right-Click protection and F10 button (important)
Post by: pietg on November 18, 2002, 10:07:00 PM
Thank you, just what I was looking for.

Piet
www.totaaldigitaal.nl
Title: There is another all too easy way.
Post by: zipper 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
Title: Re: There is another all too easy way.
Post by: Chris 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.
Title: Ok, Good
Post by: zipper 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.  :?
Title: Right-Click protection and F10 button (important)
Post by: V@no 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.
Title: Good one :)
Post by: zipper 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:
Title: Internet Explorer's Image Toolbar
Post by: fanncy pants 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?
Title: Yes
Post by: Chris 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" />
Title: Re: Yes
Post by: fanncy pants on December 01, 2002, 12:44:40 AM
:D THANKS A LOT!
Title: Right-Click protection and F10 button (important)
Post by: V@no on December 01, 2002, 12:44:53 AM
fanncy pants:
http://www.4homepages.de/forum/viewtopic.php?p=4762#4762
and this:
http://www.4homepages.de/forum/viewtopic.php?p=9220#9220