MediaWiki:Gadget-ConfirmRollback.js

// From https://en.wikipedia.org/wiki/User:MusikAnimal/confirmationRollback.js $(document).ready(function {	$(".mw-rollback-link").on('click', function(e) { var count = e.target.innerText.match(/\d/) ? e.target.innerText.match(/\d+/)[0] : null, message = 'Rollback ' + (count ? count + ' edits' : 'edit') + ' by ' + mw.util.getParamValue('from',e.target.href) + '?'; if(!confirm(message)) return e.preventDefault; }); });