Right click prevention in Netscape 7

S

Someone

I know many don't like having right click disabled, however this is a
unique case where clients using viewing this particular site will not
be world wide so it's not going to affect too many people.

I have searched google archive for this newsgroup for a solution but
similar posts never received answers.

I have a script that disables right mouse button that works in IE and
older versions of NS but it doesn't work in NS7. Can anyone please
point me to a script that works for NS7.

Thanks.
 
I

Ivo

Someone said:
I know many don't like having right click disabled,

Sure, the only reason I can fathom why this event is available to a script
at all is so that extra functionality may be provided enhancing the content
in the current context that the default behaviour doesn't. In a few rare not
to say unique cases this may be disabling all functionality, such as for
demonstration sites, sites for young children, the elderly or otherwise
easily confused. All others will only be offended. Sites that aspire a
anonymous audience but offer nothing in return (but perhaps a message in an
alert) when a user expects to cash in on the promise, are by definition
written by people who do not think. You invite guests to your house, make
them feel comfortable, light the fire for them, put up their preferred
music, and deny them a drink.
however this is a unique case
?

where clients using viewing this particular site will not
be world wide so it's not going to affect too many people.

Ah, something like an intranet. Not unique.
I have a script that disables right mouse button that works in IE and
older versions of NS but it doesn't work in NS7. Can anyone please
point me to a script that works for NS7.

Ignorance on the user's side is your only weapon in the anti-rightclick war.
In addition to users being able to drag images to desktops or straight into
their favourite image editors, take screenshots, view sources from their
Alt+F menu (or F10, a lesser known key but quite handy sometimes) or browse
their harddisk to retrieve your files, whatever it is that you wish to deny
your users, these and similar bookmarklets (client-side-*added* scripts,
start at www.bookmarklets.com) nullify any script you have or may be pointed
to:

Enable rightclick: // here and now
javascript:for(i=(f=document.frames).length;i--;)with(f){document.onmouse
down='return true';document.oncontextmenu='return
true';document.onmouseup='return true';document.body.onmousedown='return
true';document.body.oncontextmenu='return
true';document.body.onmouseup='return true';}

Strip all script: // involves reload
javascript:for(i=(f=document.frames).length;i--;)with(f){onerror=function
(){return
true};while((es=document.getElementsByTagName('script')).length){es[0].paren
tNode.removeChild(es[0]);}es=document.all;for(i=0;i<es.length;++i){e=es;f
or(p in
e){if(!p.indexOf('on')&&e[p]){e[p]=null;}}}document.write(document.documentE
lement.outerHTML);document.close();onerror=function(){return true};}void 0;

You 're welcome,
Ivo
 
D

DU

Someone said:
I know many don't like having right click disabled, however this is a
unique case where clients using viewing this particular site will not
be world wide so it's not going to affect too many people.

Your justifications are pretty weak. You provide no explanations for
disabling context menus. I'd say you're even contradicting yourself. You
say that a majority of people dislike right-click being disabled,
nevertheless you're going to go ahead with it anyway.
I have searched google archive for this newsgroup for a solution but
similar posts never received answers.

You have not searched a lot or you have not searched well. This is a
frequent question in this newsgroup.

http://jibbering.com/faq/#FAQ4_27
I have a script that disables right mouse button that works in IE and
older versions of NS but it doesn't work in NS7. Can anyone please
point me to a script that works for NS7.

Thanks.

Bug 86193: There is no way to always open the context menu upon
right-click (oncontextmenu?)
http://bugzilla.mozilla.org/show_bug.cgi?id=86193
is an enhancement request amont the most frequently requested, reported
enhancement at bugzilla.

DU
 
M

Martin Honnen

Someone said:
I know many don't like having right click disabled, however this is a
unique case where clients using viewing this particular site will not
be world wide so it's not going to affect too many people.
I have a script that disables right mouse button that works in IE and
older versions of NS but it doesn't work in NS7. Can anyone please
point me to a script that works for NS7.

As with IE you should use an oncontextmenu event handler e.g.
<img src="kiboInside.gif"
alt="Kibo inside"
oncontextmenu="return false;">
 
D

DU

Someone said:
I know many don't like having right click disabled, however this is a
unique case where clients using viewing this particular site will not
be world wide so it's not going to affect too many people.

I have searched google archive for this newsgroup for a solution but
similar posts never received answers.

I have a script that disables right mouse button that works in IE and
older versions of NS but it doesn't work in NS7. Can anyone please
point me to a script that works for NS7.

Thanks.


Yesterday, Mozilla.org honored a long time enhancement request so that
scripts no longer can disable right-click context menu, if that is the
user's wish.

Bug 86193: Prevent websites from disabling the mouse right-click context
menu - disallow sites access to Window.oncontextmenu and friends
http://bugzilla.mozilla.org/show_bug.cgi?id=86193

81 votes!

user_pref("dom.event.contextmenu.enabled", true);

DU
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,776
Messages
2,569,603
Members
45,201
Latest member
KourtneyBe

Latest Threads

Top