User:Lyrithya/rollback all.js
Jump to navigation
Jump to search
Note: After saving, you have to bypass your browser's cache to see the changes.
- Internet Explorer: hold down the Ctrl key and click the Refresh or Reload button, or press Ctrl+F5.
- Firefox: hold down the Shift key while clicking Reload; alternatively press Ctrl+F5 or Ctrl-Shift-R.
- Opera, Konqueror and Safari users can just click the Reload button.
- Chrome: press Ctrl+F5 or Shift+F5
//<nowiki> Charitwo's rollback++
function rollbackEverythingButton() {
var hasRollback = getElementsByClassName(document, "span", "mw-rollback-link");
if (hasRollback[0] && wgCanonicalSpecialPageName == 'Contributions' ) {
addPortletLink('p-cactions', 'javascript:rollbackEverything()', "Rollback all", "ca-rollbackeverything", "Rollback all top edits displayed here");
}
}
YAHOO.util.Event.onContentReady('p-cactions', rollbackEverythingButton);
function rollbackEverything() {
for (var i in document.links) {
if (document.links[i].href.indexOf('action=rollback') != -1) {
window.open(document.links[i].href+'&bot=1');
}
}
}
//</nowiki>