Gebruiker:John Vandenberg/common.js
Let op! Nadat u de veranderingen heeft opgeslagen, moet u de cache van uw browser nog legen om ze daadwerkelijk te zien.
Mozilla (incl. Firefox) | Ctrl+Shift+R |
Internet Explorer | Ctrl+F5 |
Opera | F5 |
Safari | Cmd+R |
Konqueror | F5 |
/**
* TemplateScript adds configurable templates and scripts to the sidebar, and adds an example regex editor.
* @see https://meta.wikimedia.org/wiki/TemplateScript
* @update-token [[File:pathoschild/templatescript.js]]
*/
$.ajax('//tools-static.wmflabs.org/meta/scripts/pathoschild.templatescript.js', { dataType:'script', cache:true }).then(function() {
pathoschild.TemplateScript.add([
// redirect to talk page
{
name: 'redirect to talk',
script: function(editor) {
editor
.set('#REDIRECT [[Overleg gebruiker:John Vandenberg/monobook.js]]')
.setEditSummary('Redirected to talk page');
}
},
{
name: 'Standardization and cleanup',
scriptUrl: '//en.wikisource.org/w/index.php?title=User:Pathoschild/standardise.js&action=raw&ctype=text/javascript',
script: function(editor) { standardize(editor); }
}
]);
});