The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Disable Right Mouse Click

3 posters

Go down

In progress Disable Right Mouse Click

Post by War Priest June 4th 2012, 10:10 am

Why won't this code work?

<script language=JavaScript>
<!--
var message="Disabled";
function click(z) {
if (document.all) {
if (event.button == 2) {
alert(message);
return false;
}
}
if (document.layers) {
if (z.which == 3) {
alert(message);
return false;
}
}
}
if (document.layers) {
document.captureEvents(Event.MOUSEDOWN);
}
document.onmousedown=click;
// -->
</script>

I am not that computer nerdy so not sure. I have tried <head></head> and still won't work.

EDIT: Think I posted in the wrong sub forum. Was looking at script earlier and must have moved.
avatar
War Priest
New Member

Posts : 7
Reputation : 1
Language : English

Back to top Go down

In progress Re: Disable Right Mouse Click

Post by SLGray June 4th 2012, 10:32 am



Disable Right Mouse Click Slgray10

When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
SLGray
SLGray
Administrator
Administrator

Male Posts : 51481
Reputation : 3519
Language : English
Location : United States

https://forumsclub.com/gc/128-link-directory/

Back to top Go down

In progress Re: Disable Right Mouse Click

Post by War Priest June 4th 2012, 8:28 pm

Yes, and it doesn't work.

Also, instead of adding it to the whole site, can I just add it to one topic?
avatar
War Priest
New Member

Posts : 7
Reputation : 1
Language : English

Back to top Go down

In progress Re: Disable Right Mouse Click

Post by kirk June 5th 2012, 2:43 am

One topic only or all topics?
Rideem3 code would be for all topics?



kirk
kirk
Forumaster

Male Posts : 11037
Reputation : 653
Language : English,Vulcan,Klingon, Romulan,& Gorn

Back to top Go down

In progress Re: Disable Right Mouse Click

Post by War Priest June 5th 2012, 3:19 am

Just one topic. If not possible I can settle for all topics.
avatar
War Priest
New Member

Posts : 7
Reputation : 1
Language : English

Back to top Go down

In progress Re: Disable Right Mouse Click

Post by War Priest June 5th 2012, 3:49 am

Thanks Rideem3. How do I do it for just one topic?
avatar
War Priest
New Member

Posts : 7
Reputation : 1
Language : English

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum