Difference between revisions of "MediaWiki:Common.js"

From Documentation
m
Line 10: Line 10:
 
     "sampleText": ""}
 
     "sampleText": ""}
 
   }
 
   }
 +
/* CharInsert */
 +
 +
var load_edittools = true;
 +
// extra drop down menu on editing for adding special characters
 +
importScript( 'MediaWiki:Edittools.js' );
 +
// Editpage scripts
 +
if( wgAction == 'edit' || wgAction == 'submit' ) {
 +
importScript( 'MediaWiki:Editpage.js' );
 +
}

Revision as of 12:10, 14 February 2011

/* Any JavaScript here will be loaded for all users on every page load. */

 if (mwCustomEditButtons) {
 
   mwCustomEditButtons[mwCustomEditButtons.length] = {
     "imageFile": "/_w/images/7/79/Button_reflink.png",
     "speedTip": "Reference",
     "tagOpen": "<ref> ",
     "tagClose": " </ref>",
     "sampleText": ""}
  }
/* CharInsert */ 

var load_edittools = true;
// extra drop down menu on editing for adding special characters
importScript( 'MediaWiki:Edittools.js' );
// Editpage scripts
if( wgAction == 'edit' || wgAction == 'submit' ) {
	importScript( 'MediaWiki:Editpage.js' );
}