Opening URL in New Tab doesn't work in existing, programmatically-opened New Window (Firefox)
- by seth
I am building a web app, for myself, to control some servers on my home network, and discovered what I think is very odd behavior in Firefox.
If you open a pop-up, via javascript, in Firefox, is it then impossible to open a new tab, via javascript in that pop-up? If not impossible, how do you do it?
Given a clean, default Firefox 3.6.3 installation...
If I open a page in Firefox and then call
var my_window = window.open('http://www.google.com','_blank','top=10');
A brand new "pop-up" window opens.
However, if instead I call
var my_window = window.open('http://www.google.com');
A get a new tab.
HOWEVER...
If I call the first version
var my_window = window.open('http://www.google.com','_blank','top=10');
And then in the new "pop-up" that opens, I call
var my_window = window.open('http://www.google.com');
It opens a new tab in the original window, not a new tab in the pop-up.
This seems very odd, and not intuitive at all. Why would the call in the pop-up open a tab in the "parent" window?