MediaWiki:Common.js
Hop til navigation
Bemærk: Efter at have gemt er du måske nødt til at tømme din browsers cache for at kunne se ændringerne.
- Firefox / Safari: Hold Shift nede og klik på Reload, eller tryk enten Ctrl-F5 eller Ctrl-R (⌘-R på en Mac).
- Google Chrome: Tryk Ctrl-Shift-R (⌘-Shift-R på en Mac).
- Internet Explorer / Edge: Hold Ctrl nede og klik på Refresh, eller tryk på Ctrl-F5.
- Opera: Go to Menu → Settings (Opera → Preferences on a Mac) and then to Privacy & security → Clear browsing data → Cached images and files
/* Any JavaScript here will be loaded for all users on every page load. */ $('.tbbox-logo').wrap('<a href="/wiki/Forside"></a>'); if ($('.item_container').length!==0) { $('.item_container').each(function() { $(this).append('<img src="https://westzz.innogamescdn.com/images/items/' + $(this).attr('data-url') + '?1">'); }); $.getScript("https://wiki.the-west.dk/wiki/Popup.js?action=raw"); } $(window).scroll(function() { if ($(this).scrollTop() > 300) { $('#back-top').fadeIn(); } else { $('#back-top').fadeOut(); } }); // Scroll body to top on click $('#back-top a').click(function() { $('body,html').animate({ scrollTop: 0 }, 800); return false; }); // Embed youtube videos if ($('.youtube_video').length !== 0) { $('.youtube_video').each(function() { $(this).html('<iframe width="100%" height="100%" src="https://www.youtube.com/embed/' + $(this).attr('data-id') + '?cc_load_policy=1&cc_lang_pref=' + $(this).attr('data-subtitles') + '" frameborder="0" allowfullscreen></iframe>'); }); } $(".prq_dispo b").each(function() { $(this).text($(this).text().replace(/from/g, "Fra").replace(/at/g, "kl.").replace(/until/g, "indtil")); });