Open
Bug 394699
Opened 17 years ago
Updated 2 months ago
With "open in same window/tab" pref, target=_blank can exit browser
Categories
(Firefox :: File Handling, defect)
Tracking
()
NEW
People
(Reporter: akkzilla, Unassigned)
Details
Attachments
(1 obsolete file)
Links to mime types that require an external application can exit the current tab or window (and potentially the whole browser session) if you set your preferences so that target="_blank" opens in the current window and tab. For example, I have: user_pref("browser.link.open_external", 1); user_pref("browser.link.open_newwindow", 1); Now make a page which does this: <a href="foo.pdf" target="_blank">click here to exit</a> (where foo.pdf points to an actual pdf file somewhere, or some other file type that would call up the helper app dialog). With only one window and one tab visible, click on the link. The current window disappears, then the mime type helper app dialog appears. Sometimes you can call up the helper app, sometimes not (there might be a race condition there) but the important thing is that no matter what, you've lost your browser window. I haven't tried this with mime types that don't display the helper app dialog. In bug 346561 ("Always close useless tabs/windows opened for external handling") the first comment is "We already do this for windows opened through target="_blank" and window.open(...)." I suspect that the "already do this" code is being a bit too eager, and not noticing whether a new tab or window is actually opened before deleting the current one. The code should check whether it actually opened a new window, and only in that case should it close it.
Updated•17 years ago
|
Product: Firefox → Core
QA Contact: file.handling → file-handling
Version: 2.0 Branch → Trunk
Comment 1•17 years ago
|
||
The code that closes "blank" windows after a download is in nsExternalHelperAppService (see bug 343921 and bug 241972). Also note that pref("browser.link.open_external", 1); is not "supported" by Firefox (there's no UI to set that pref to 1).
Comment 2•17 years ago
|
||
See also bug 324164, which proposes removing that pref altogether.
Updated•8 years ago
|
Product: Core → Firefox
Version: Trunk → unspecified
Updated•2 years ago
|
Severity: normal → S3
Comment hidden (spam) |
Updated•2 months ago
|
Attachment #9387312 -
Attachment is obsolete: true
You need to log in
before you can comment on or make changes to this bug.
Description
•