Jump to content

Disable "Save Image" or "Right Mouse Click"

Guest jalewin

Recommended Posts

Guest jalewin

I'd like to disable the "save image as" option from the mouse right click button. Any suggestions where I can find

tutorial for that?  If no, how would I disable right mouse click?


Link to comment
Share on other sites

Welcome jalewin! Glad to see you made it to the forums.


Your needs are not really specific to CubeCart, so I have no solution for you. I suggest you google for a solution.


If your solution is in fact a jQuery statement that disables the contextmenu, such as:

$(this).bind("contextmenu", function(e) {e.preventDefault();});

you can insert this just after the very first line of /js/common.js.


Any other solution that specifically targets the manipulation of your images, once you find one, the best place to incorporate it is at the end of /js/common.js.

Link to comment
Share on other sites

Guest jalewin

Thank you B Smither & Kraken for your replies.

I realise that it is only a very basic impediment to those who want to take images, but it is a first line of defense. When I used CC ver4, I used the script below in the header.inc.php file and it worked. I can't seem to find the header.inc.php file in CC ver5. I found this Script in one of these Forums.

" Just put this into your header.inc.php (somwhere between the <head> and </head>

Ie right under the:

< style type="text/css">


@import url(<?echo"$site_url";?>/admin/style.css);


< /style>



<script language="Javascript1.2">

< !--

var msg = "I am glad you liked my photos.";

if(document.layers) window.captureEvents(Event.MOUSEDOWN);

function no_click(e){

if (navigator.appName == 'Netscape' && ( e.which == 2 || e.which == 3))


alert(msg);return false;


if (navigator.appName == 'Microsoft Internet Explorer' && (event.button == 2 || event.button == 3))


alert(msg);return false;



Posted 07 November 2004 - 10:39 PM




< /script>"

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...