0

I am using Firefox to automatically navigate and capture screenshots from various websites. Some of these websites use the onbeforeunload event to capture a user's attention before leaving a page.

Right now, this prevents my script from navigating to the next URL and I have to run the following JS to redefine the event to do nothing, like below:

window.onbeforeunload = function () {};

I'd like to put this logic in the browser and not to deal with a bunch of edge-cases in my code. Ideally keeping Javascript enabled, whilst blocking this event (possibly others) on all pages the browser visits.

Is this possible through a known extension or via Firefox profile settings?

2

0

You must log in to answer this question.

Browse other questions tagged .