This site will have limited functionality while we undergo maintenance to improve your experience. If an article doesn't solve your issue and you want to ask a question, we have our support community waiting to help you at @FirefoxSupport on Twitter and/r/firefox on Reddit.

Caută ajutor

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Află mai multe

Acest fir de discuție a fost arhivat. Adresează o întrebare nouă dacă ai nevoie de ajutor.

Firefox - Javascript prevents me from closing tab - security vulnerability - installs malware or just annoying

  • 4 răspunsuri
  • 1 are această problemă
  • 1 vizualizare
  • Ultimul răspuns de FredMcD

more options

Some times a website hijacks your tab and won't allow you to close it unless you choose an option. If you choose yes or no then it install a virus or malware.

In chrome you can just hold enter and then close window and if force closes browser window. Only option is to force close the entire browser window via the task manager or agree to the terms.

I believe javascript should not prevent you from closing the browser tab/window or at least write an internal over ride that will terminate any script running in the browser in the current tab. Otherwise why did I choose to close it in the first place.

There might be legitimate reason to allow this but you should offer an override. Also from a user stand point there are many people out there that have little to no information about how a browser or tech works. Someone like my dad who is over 50 years old and struggles to us the internet or smart phone. He would not know how to deal with this. Thus would end up installing the virus.

Anyway I have yet to see anywhere this is a useful feature. Mostly used on bad websites. I don't want to disable javascript for the browser. I just want close a tab.

just before submitting this I encountered one window that if closed it would open up 2 more tabs. All with the same problem.

So if I was going to code this I would code as some kind of button you hold down on the keyboard or right click and then terminates the script in the tab and then closes the tab. Like force quit a program.

Some times a website hijacks your tab and won't allow you to close it unless you choose an option. If you choose yes or no then it install a virus or malware. In chrome you can just hold enter and then close window and if force closes browser window. Only option is to force close the entire browser window via the task manager or agree to the terms. I believe javascript should not prevent you from closing the browser tab/window or at least write an internal over ride that will terminate any script running in the browser in the current tab. Otherwise why did I choose to close it in the first place. There might be legitimate reason to allow this but you should offer an override. Also from a user stand point there are many people out there that have little to no information about how a browser or tech works. Someone like my dad who is over 50 years old and struggles to us the internet or smart phone. He would not know how to deal with this. Thus would end up installing the virus. Anyway I have yet to see anywhere this is a useful feature. Mostly used on bad websites. I don't want to disable javascript for the browser. I just want close a tab. just before submitting this I encountered one window that if closed it would open up 2 more tabs. All with the same problem. So if I was going to code this I would code as some kind of button you hold down on the keyboard or right click and then terminates the script in the tab and then closes the tab. Like force quit a program.

Toate răspunsurile (4)

more options

hello samsoundguy, i agree that this should not be allowed to happen - could you file a bug report for this issue including the offending url at [bugzilla.mozilla.org]? thanks a lot!

more options

Chrome currently creates a separate process (you can see it in the Windows Task Manager) per window or per tab. That makes the killing of a single window or tab separate from the rest of the windows and tabs. Firefox has a feature in development that will spawn separate content processes, but it's taking time to get the kinks out: https://developer.mozilla.org/en-US/Firefox/Multiprocess_Firefox While that means some delay before your suggestion could be implemented, it also means an opportunity to make sure it is fully featured when it arrives.

more options

You can also possibly set the dom.disable_beforeunload prefto true on the about:config page.

You can open the about:config page via the location/address bar. You can accept the warning and click "I'll be careful" to continue.

more options

This add-on can stop such pages; disallow Script Button {web link} The Disallow Script button looks like a letter "M" and the title is the Minus Script, drag and drop the button on a toolbar. If the button is not displayed then nothing operates, except rules for plugins.