My Weblog
02 03 2005

Wed, 02 Mar 2005

Tweaking Firefox's Popup Blocker
Recently advertisers have figured out how to get around firefox's popup blocker. Normally, firefox blocks popups except for those that happen within a specified interval of user actions like click, double click, submit, etc. The problem is that some sites like zophar.net are set up so that most links have a javascript onClick handler that displays a popup ad. There's a way around this. Modify the dom.popup_allowed_events property to have the value 'change #click dblclick #mouseup reset submit'. This property specifies which events may create popup windows.

Commenting out 'mouseup' and 'click' allows popups associated with forms to work but stops onClick ads. Unfortunately, it also breaks sites that use onClick to do something useful, like display an image in a new window (which is still evil, but at least it's not an ad). If this breaks a particular site, set firefox to allow popup ads from it.

See this Slashdot thread for more useful stuff.

posted at: 09:04 | path: /computers/linux/apps/firefox | permanent link to this entry