Possible Duplicate:
why window.focus() not working in Mozilla firefox?
I am implementing multitab feature for my application and I am finding difficulties to implement those when it comes to set the focus for the opened window. Firefox sets the focus for the first time when the window is opened but next time it doesnt.
For example -
My application always opens in window with name 'baseWindow'. A page has following link -
Link1 - Opens a new window with name 'window2'
onclick for above link has following function
function linkOnClick(){
var wind1=window.open('window2Page.html','window2');
wind1.focus();
}
When the link is clicked for the first time i.e. window2 doesnt exists, at that time the focus is automatically given to window2. But if i come on first window and click on the link again then the focus is not given on the window2 it stays on the same window.