Open main menu

MediaWiki/js

< MediaWiki
Revision as of 10:22, 22 June 2016 by Freephile (talk | contribs)

(diff) ← Older revision | Approved revision (diff) | Latest revision (diff) | Newer revision → (diff)

The first thing to know about MediaWiki and JavaScript is that the site administrator can customize the wiki installation by simply modifying the article MediaWiki:Common.js

For instance, if you put the JavaScript code for wikEd in there, it will make the WikEd editor available to all users of the local wiki.

Debugging JavaScript

  1. Access the developer tools of your browser
    • Chrome CTRL + SHIFT + J
    • Firefox CTRL + SHIFT + I
  2. Go to the console tab (look for errors)
  3. append ?debug=true to the URL and reload the page. This will give you non-minified JavaScript.