Prevent websites from disabling right-click

Bug #23632 reported by Corey Burger
22
This bug affects 1 person
Affects Status Importance Assigned to Milestone
firefox (Ubuntu)
Fix Released
Low
Ian Jackson

Bug Description

Some website, such as http://www.formula1.com/ prevent Firefox from using right
click. This is simply unacceptable. I believe there is an option in Firefox
(disabled by default) to stop this activity.

Revision history for this message
Corey Burger (corey.burger) wrote :

Oh, and this should target dapper

Revision history for this message
Daniel Robitaille (robitaille) wrote :

While it is very annoying, I personally think it is something that should be
dealt with the site owners, not with at the browser level since this "feature"
is intentionally done by the web site authors, using standard features of the
Javascript language.

But if you really need to access right-click options for a site, simply disable
javascript, or go into Edit --> Preference --> Web Features --> Javascript
Advanced and unselect "Disable or replace content". If you do the later, you
still get the warning the site authors wanted you to see, but it is immediatelly
followed by the right-click menu. At least that's the behaviour at
http://www.formula1.com/

Revision history for this message
Corey Burger (corey.burger) wrote :

The site owners are never going to agree to that. It is MY computer and I do
with it as I like. If we let them win this one, where do we stop?

Revision history for this message
Dennis Kaarsemaker (dennis) wrote :

I wouldn't say this is a bug in firefox, but a misfeature in Javascript. There
is a firefox extension to disable this behaviour.

Revision history for this message
Ian Jackson (ijackson) wrote :

I agree that this is a bug in Firefox. A web browser should do the bidding of
the user first, and of the website second. Any standard which says otherwise
(eg, JavaScript) should not be followed by us, because our job is to serve our
users.

However, since there may well be legitimate sites that this breaks I don't want
to change it at this stage of Ubuntu's release cycle.

Revision history for this message
Corey Burger (corey.burger) wrote :

Ian, absolutely. Lets implement this early in Dapper and test it heavily.

Revision history for this message
Corey Burger (corey.burger) wrote :

Ian, how much work is this to push now?

Revision history for this message
Ian Jackson (ijackson) wrote :

I think this should be fixed in firefox 1.4.99+1.5rc3.dfsg-1ubuntu6.

Please could you check and confirm.

Revision history for this message
Alan Tam (at) wrote :

I oppose this change, which made Ubuntu different from all other distros.
There are legitimate uses to disable context menu, e.g. most Web 2.0
applications provide their own context menu, by capturing oncontextmenu entirely.
Under the principle of least surprise, We should follow the upstream default.
If you can convince upstream to change this, I've no objection for that.

Revision history for this message
Corey Burger (corey.burger) wrote :

Alan, find us a website that this breaks and then we can talk about it more.

Revision history for this message
Alan Tam (at) wrote :

I think at least a couple of Web 2.0 applications [1] are affected. See e.g. [2]
- click "Go to Demo", type the word, and right click on the thread pane.
As a matter of fact, some of my company's intranet applications also uses this
feature, but I failed to show you.

[1] http://www.ajaxmatters.com/r/resources?id=2
[2] http://www.zimbra.com/products/hosted_demo.php

Revision history for this message
Alan Tam (at) wrote :

I do not have permission to reopen this bug. Can somebody do for me?

Revision history for this message
Corey Burger (corey.burger) wrote :

Can you raise the issue on ubuntu-devel mailing list? It might need more discussion.

Revision history for this message
Ian Jackson (ijackson) wrote :

> I oppose this change, which made Ubuntu different from all other distros.
> There are legitimate uses to disable context menu, e.g. most Web 2.0
> applications provide their own context menu, by capturing oncontextmenu entirely.

The majority of cases where the context menu is disabled are still regrettably
sites which attempt to prevent (eg) the user saving images, and the like. It
would be simply wrong of us to make the user's computer obey the site owner's
request to disable functionality the user may find useful.

It would be all right if there were a way to get both context menus but this is
a change that ought to come from upstream and I don't think we have the effort
to fix it.

As Corey says, if you still disagree I think the ubuntu-devel list would be the
right place to discuss it.

Revision history for this message
Alan Tam (at) wrote :

Why do we honour request for opening a new window (by window.open()) without
menubar, urlbar, statusbar, etc? I don't think these are not features "most
users find useful". Do my browser obey me? How many phishing problems caused by
this feature have we fixed between FF0.9 and FF1.0? If I am the judge, I will
stick to the rule of common law - allow it unless it is guilty, beyond
reasonable doubt.

If you find the discussion here not fruitful, so do I. That's why I insisted
that we should discuss it upstream. I didn't send this to ubuntu-devel, since I
don't think I have the time to monitor the discussion there, without the
bugzilla-like alert features. If you like, you can still post there.

Personally I am not so interested in the result of the discussion. However,
Ubuntu itself is interested, especially when it wants to position itself as the
only distribution which has this feature "disabled" (or enabled, as you like),
and it has to accept its own marketing consequence being commented "Web 2.0
unfriendly".

Revision history for this message
Valentin Neacsu (valentin.neacsu) wrote :

Sorry to dig this up, but I'm using Intrepid with Firefox 3.0.5 and this still happens. Why is the option in Edit->Preferences->Content to disallow websites to disable my right click/context menu ignored?

Best example is the new Ajax interface for Yahoo! Mail.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related questions

Remote bug watches

Bug watches keep track of this bug in other bug trackers.