User: Markhurd/common.js

(Canonical name is ConfirmAccounts)
(Remove legacy code.)
 
(11 intermediate revisions by the same user not shown)
Line 1: Line 1:
// [[Wikipedia:Tools/Navigation popups]]
mw.loader.load('https://en.wikipedia.org/w/index.php?title=MediaWiki:Gadget-popups.js&action=raw&ctype=text/javascript');
mw.loader.load('https://en.wikipedia.org/w/index.php?title=MediaWiki:Gadget-navpop.css&action=raw&ctype=text/css', 'text/css');
userHideAllSubsequent=true;
// [[User:Markhurd/hidetopcontrib.js]]
importScript('User:Markhurd/hidetopcontrib.js');
// when id="submitSpam" onclick="document.getElementById('wpComment').style.display='none';form.elements[11].focus()"
// when id="submitSpam" onclick="document.getElementById('wpComment').style.display='none';form.elements[11].focus()"


addOnloadHook(function () {
jQuery( function( $ ) {
   if(wgCanonicalSpecialPageName == 'ConfirmAccounts')
   if ( mw.config.get( 'wgCanonicalSpecialPageName' ) == 'ConfirmAccounts')
     $('.submitSpam').click(function() {
  {
     $('#submitSpam').click(function() {
             document.getElementById('wpComment').style.display='none';
             document.getElementById('wpComment').style.display='none';
             form.elements[11].focus();
             this.form.elements[11].focus();
         });
         });
  };
  });
  });

Latest revision as of 14:33, 9 February 2016

// [[Wikipedia:Tools/Navigation popups]]
mw.loader.load('https://en.wikipedia.org/w/index.php?title=MediaWiki:Gadget-popups.js&action=raw&ctype=text/javascript');
mw.loader.load('https://en.wikipedia.org/w/index.php?title=MediaWiki:Gadget-navpop.css&action=raw&ctype=text/css', 'text/css');

userHideAllSubsequent=true;

// [[User:Markhurd/hidetopcontrib.js]]
importScript('User:Markhurd/hidetopcontrib.js');

// when id="submitSpam" onclick="document.getElementById('wpComment').style.display='none';form.elements[11].focus()"

jQuery( function( $ ) {
   if ( mw.config.get( 'wgCanonicalSpecialPageName' ) == 'ConfirmAccounts')
   {
     $('#submitSpam').click(function() {
            document.getElementById('wpComment').style.display='none';
            this.form.elements[11].focus();
        });
   };
 });
Discuss this page