In my Rails application, at a certain stage, it was necessary that my user performs an operation in another web-application (a GIS application) on the same database. I am using the following piece of code to make sure that i open a url in a new window, and that it should get the focus (jump to the front).
function newWindow(newContent, windowName)
var new_window = window.open(newContent, windowName);
if (window.focus) new_window.focus();
newWindow('<%= link_to_location @mention, true %>', '<%= @gisapp_window_name %>');
<% end -%>
All is well when the window is first opened, but if the window was already opened, still it fails.
And of course i do all testing against firefox 3.5, although my user wants to use IE instead. So i try in IE and it works. Huh?
So it has something to do with Firefox 3.5.
And behold, as explained here