2010-02-16 03:35:59 +01:00
|
|
|
function windowName(suffix) {
|
|
|
|
var base = document.getElementsByTagName('base')[0].href.replace('http://','').replace(/\//g,'_').replace(/\./g,'_');
|
|
|
|
return base + suffix;
|
|
|
|
}
|
|
|
|
|
|
|
|
(function($) {
|
2010-03-11 05:37:18 +01:00
|
|
|
$('#switchView a.newWindow').live('click',
|
2010-02-16 03:38:46 +01:00
|
|
|
function() {
|
|
|
|
var w = window.open(this.href, windowName(this.target));
|
|
|
|
w.focus();
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
);
|
|
|
|
|
2010-03-11 05:37:18 +01:00
|
|
|
$('#SilverStripeNavigatorLink').live('click',
|
2010-02-16 03:35:59 +01:00
|
|
|
function() {
|
|
|
|
$('#SilverStripeNavigatorLinkPopup').toggle();
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
);
|
|
|
|
|
2010-03-11 05:37:18 +01:00
|
|
|
$('#SilverStripeNavigatorLinkPopup a.close').live('click',
|
2010-02-16 03:40:19 +01:00
|
|
|
function() {
|
|
|
|
$('#SilverStripeNavigatorLinkPopup').hide();
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
);
|
|
|
|
|
2010-03-11 05:37:18 +01:00
|
|
|
$('#SilverStripeNavigatorLinkPopup input').live('focus',
|
2010-02-16 03:35:59 +01:00
|
|
|
function() {
|
|
|
|
this.select();
|
|
|
|
}
|
|
|
|
);
|
|
|
|
|
|
|
|
})(jQuery);
|