6

Firefox has long had a feature to protect users from over-aggressive Javascript websites that would generate repeated pop-ups to trick or annoy visitors. Is there a way to disable this protection on specific websites, rather than disabling it entirely?

I've found a way of doing the latter and while it's been years since I've seen one of those popup-bait websites I'd rather not risk my browser's security or stability by disabling the warning globally.

While I understand that any legitimate website has no business abusing pop-ups in this fashion, the ERP portal that I need to use introduced this amazing pop-up feature in a recent update.

Note: this question is about disabling the warning from the user-side.

3 Answers3

4

This behaviour can be controlled by setting the config parameter dom.successive_dialog_time_limit. This integer value represents a time window in seconds since the last pop-up. If a website generates a new pop-up within that window, Firefox will instead trigger the "Prevent..." dialog.

To set this value:

  1. Copy this string to your clipboard: dom.successive_dialog_time_limit
  2. In FireFox Address bar Enter: about:config and press enter.
  3. Accept the warning dialog.
  4. In the preferences area right-click.
  5. Select New-> Integer
  6. Paste the string you copied previous and click OK
  7. Enter the integer 0 in the next dialog box and click OK.1
  8. Close the about:config page.


1: for most cases, setting this value to 1 or 2 seconds will be sufficient to allow pop-up heavy websites to work without interruption while still stopping malicious infinite pop-up JavaScript code.

0

Try this

if (confirm("Do stuff?")) 
  Dostuff(); 
else 
  location.reload(); 
zx485
  • 2,337
Abel
  • 1
0

Take a look at the noscript firefox extension. By default all js is disabled. You then selectively enable it as and when needed:

The NoScript Firefox extension provides extra protection for Firefox, Seamonkey and other mozilla-based browsers: this free, open source add-on allows JavaScript, Java, Flash and other plugins to be executed only by trusted web sites of your choice (e.g. your online bank).

NoScript also provides the most powerful anti-XSS and anti-Clickjacking protection ever available in a browser.

NoScript's unique whitelist based pre-emptive script blocking approach prevents exploitation of security vulnerabilities (known and even not known yet!) with no loss of functionality...

DavidPostill
  • 162,382