Firefox 8.0, 9.0, 10.0 block popup from bookmarklets

RESOLVED DUPLICATE of bug 679961

Status

()

defect
RESOLVED DUPLICATE of bug 679961
8 years ago
8 years ago

People

(Reporter: sunflowers_1, Unassigned)

Tracking

10 Branch
x86
Windows XP
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

8 years ago
User Agent: Mozilla/5.0 (Windows NT 5.1; rv:10.0a1) Gecko/20111025 Firefox/10.0a1
Build ID: 20111025031041

Steps to reproduce:

Test this bookmarklets: javascript:(%20function(){%20var%20transText%20=%20'';%20if%20(window.getSelection)%20{%20transText%20=%20window.getSelection();%20}%20else%20if%20(document.getSelection)%20{%20transText%20=%20document.getSelection();%20}%20else%20if%20(document.selection)%20{%20transText%20=%20document.selection.createRange().text;}%20var%20a=window,b=document,c=encodeURIComponent,d=a.open('http://translate.google.com/translate_t?text='+transText+'&sl=auto&tl=en'%20,'gTranslate_popup','left='+((a.screenX||a.screenLeft)+10)+',top='+((a.screenY||a.screenTop)+10)+',height=480px,width=750px,resizable=1,scrollbars=1');a.setTimeout(function(){d.focus()},300)})();

Or: http://pastebin.com/neEPbQxi

Select random text, execute this bookmarklet.


Actual results:

Translate popup window get blocked.


Expected results:

Popup window must appear like Firefox 7.0 and lower.
document.getSelection() returns "object" since Firefox 8, no longer "string". See bug 636512.
Status: UNCONFIRMED → RESOLVED
Last Resolved: 8 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 636512
(Reporter)

Comment 2

8 years ago
But so much bookmarklets stopped working after that change, will have a fix for popup blocker ? But still work fine on Chrome, Opera, IE and other browser, for sure.

Example: javascript:(function(){w=open(('http://www.bugmenot.com/view/'+encodeURIComponent(location.host)),'w','location=no,status=yes,menubar=no,scrollbars=yes,resizable=yes,width=500,height=400,modal=yes,dependent=yes');if(w){setTimeout('w.focus()',1000)}else{location='http://www.bugmenot.com/view/'+encodeURIComponent(location.host)}})();

javascript:q=(document.location.href);void(open('http://www.designfloat.com/submit.php?url='+escape(q),'','resizable,location,menubar,toolbar,scrollbars,status'));

javascript:q=(document.location.href);t=(document.title);s=(document.getSelection());void(open('http://designmoo.com/submit?url='+encodeURIComponent(location.href)+'&title='+encodeURIComponent(document.title)+'&body='+encodeURIComponent(document.getSelection()),'',''));

Comment 3

8 years ago
> *** This bug has been marked as a duplicate of bug 636512 ***
Woudn't this be a dup of bug 690997 and blocking bug 636512?

Wasn't the purpose of bug 636512 compatibility with Chrome (10) and IE9?
This bug is unrelated to the document.getSelection() change. If I change open() to alert(), I see the selected string is concatenated correctly. Moreover, the bookmarklet in comment #1 will choose window.getSelection() which was not be changeed by bug #636512.
Probably something about popup-blocker has been changed between Fx7 and Fx8.
Status: RESOLVED → UNCONFIRMED
Resolution: DUPLICATE → ---
Cattleya, could you bisect nightly builds to find what changeset caused this issue?

Updated

8 years ago
Status: UNCONFIRMED → RESOLVED
Last Resolved: 8 years ago8 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 679961

Updated

8 years ago
You need to log in before you can comment on or make changes to this bug.