User:Duskey/monaco.js
Jump to navigation
Jump to search
Important note on account security
Code that you insert on this page could contain malicious content capable of compromising your account. If you import a script from another page with
importScript
or iusc
, take note that this causes you to dynamically load a remote script, which could be changed by others. The code will be executed when you preview this page.Note: After saving, you may have to bypass your browser's cache to see the changes.
- Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
- Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
- Internet Explorer: Hold Ctrl while clicking Refresh, or press Ctrl-F5
- Edge: Press Ctrl-Shift-Del, select Cached data and files, and click Clear
- Opera: Go to Menu → Settings (Opera → Preferences on a Mac) and then to Privacy & security → Clear browsing data → Cached images and files.
if ((wgAction == 'view' || wgAction == 'purge') && wgCanonicalNamespace != 'Special') {
$(document).ready(function() {
var list = null;
if (skin == 'monobook') {
list = document.getElementById('p-tb').getElementsByTagName('ul')[0];
} else {
var lists = document.getElementById('link_box').getElementsByTagName('ul');
if (lists[0].getElementsByTagName('li').length <= lists[1].getElementsByTagName('li').length) {
list = lists[0];
} else {
list = lists[1];
}
}
var li = document.createElement('li');
var a = document.createElement('a');
a.href = wgScript + '?action=purge&title=' + encodeURIComponent(wgPageName);
a.appendChild(document.createTextNode('Purge this page'));
a.title = 'Clear the server cache of this page.';
li.appendChild(a);
list.insertBefore(li, list.firstChild);
});
}