User:The Fizzbuzzler/spam.js

// //opening links if (wgPageName == 'User:Cook_Me_Plox/Sandwich') { $(function {       $('').appendTo('h1').click(function { $('div#bodyContent a[href*="spam"]').each(function {               window.open($(this).attr('href'));            }); });   }); } //executing if (window.location.href.match(/&spam=yes/) && wgAction == 'edit' && wgCanonicalNamespace == 'File') { $(function {       var page = decodeURIComponent(window.location.href.match(/&page=(.*)/)[1]);        $('textarea#wpTextbox1').val($('textarea#wpTextbox1').val.match(/\[\[Category:(.*)\]\]|\{\{(.*)\}\}/g));        $('textarea#wpTextbox1').val('\n' + $('textarea#wpTextbox1').val.replace(/,/g, '\n'));        $('input#wpDiff').click;    }); } //