Tweak to bring window back to front when already open
Posted: Wed Jan 13, 2010 8:06 pm
In firefox (and I suspect other browsers), if you already have a particular window open, clicking a link to reopen (ie Montage, etc), doesn't appear to do anything since the window is open behind the current one. To fix, in the skins/classic/js folder, edit the file skins.js to change function createPopup by adding the last line (in bold) shown.
function createPopup( url, name, tag, width, height )
{
var popupSize = getPopupSize( tag, width, height );
var popupDimensions = "";
if ( popupSize.width > 0 )
popupDimensions += ",width="+popupSize.width;
if ( popupSize.height > 0 )
popupDimensions += ",height="+popupSize.height;
var popup = window.open( url, name, popupOptions+popupDimensions );
if (window.focus) {popup.focus()}
}
function createPopup( url, name, tag, width, height )
{
var popupSize = getPopupSize( tag, width, height );
var popupDimensions = "";
if ( popupSize.width > 0 )
popupDimensions += ",width="+popupSize.width;
if ( popupSize.height > 0 )
popupDimensions += ",height="+popupSize.height;
var popup = window.open( url, name, popupOptions+popupDimensions );
if (window.focus) {popup.focus()}
}