MediaWiki:Common.js: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
| Line 2: | Line 2: | ||
$(document).ready(function() { | $(document).ready(function() { | ||
$('a').once('popup-link').each(function() { | $('a').once('popup-link').each(function() { | ||
var href = $(this).attr('href'); | var href = $(this).attr('href'); | ||
if (href && href.startsWith('https://www.lotico.com')) { | |||
if (href && href.startsWith(' | |||
$(this).on('click', function(e) { | $(this).on('click', function(e) { | ||
e.preventDefault(); | e.preventDefault(); | ||
window.open(this.href, 'popupWindow', 'width=600,height=400,scrollbars=yes,resizable=yes'); | window.open(this.href, 'popupWindow', 'width=600,height=400,scrollbars=yes,resizable=yes'); | ||
}); | }); | ||
Revision as of 20:43, 6 September 2025
/* Any JavaScript here will be loaded for all users on every page load. */
$(document).ready(function() {
$('a').once('popup-link').each(function() {
var href = $(this).attr('href');
if (href && href.startsWith('https://www.lotico.com')) {
$(this).on('click', function(e) {
e.preventDefault();
window.open(this.href, 'popupWindow', 'width=600,height=400,scrollbars=yes,resizable=yes');
});
}
});
});