Monday, May 12, 2008

Stop Annoying JavaScript

By Oli on Thursday, 08th June 2006. More information. Comments.

An example of such a page is the ScanAlert website which is linked to from all around the web declaring sites "Hacker Safe". When you click the image, you're linked to their details page about the site you're on (have a look at their review of Experts-Exchange**WARNING** Annoying JS on page) and promptly attempts to resize your browser to a miniscule size.

This is by no means the only example of a site doing this Many sites with bad advertising on can spawn full-screen pop-unders and the like. I've seen other sites using variants of the following JavaScript function that prevents you from resizing your window.

Extremely annoying if they make the browser bigger than the screen.

Combating Annoying JS in Firefox

The first thing is to get yourself into the options screen of Firefox, accessible from the Tools >> Options... menu.

If you're using the latest version of Firefox (1.5.0.4) you want to head for the tab labeled Content. If you're using an older version you might be looking for a tab named Web Features.

In here you're looking for checkbox and label that says Enable JavaScript. Do not disable this unless you want to block all javascript. Instead click the button along from it, labeled Advanced.

FireFox Options Screen

And here it is as it is after you do a default install of Firefox. Its already disabled status-bar-editing but still allows JS to resize and move windows, popping windows to the front and adding extra behavior to the right click context menu.

All of these can be annoying JavaScript at some point on the web. It really depends on how the developer has made the site. Disabling any of these could stop a site you need to use from working, which might be an issue for you, but if you don't have any sites which do any of those things, I strongly suggest unchecking all of those checkboxes and clicking OK to both the open windows.

Advanced JS Options before

At the end of it, you should have something that looks a lot like this. If you need the feature reenabled, just come back to the screen and check the features you need.

The most important thing about all of this is you remember where the screen is, so you can turn things back on if you need to access a site that urgently needs these parts of javascript to function.


Advanced JS Options before

link

No comments: