RationalWiki's 2020 Fundraiser

There is no RationalWiki without you. We are a small non-profit with no staff – we are hundreds of volunteers who document pseudoscience and crankery around the world every day. We will never allow ads because we must remain independent. We cannot rely on big donors with corresponding big agendas. We are not the largest website around, but we believe we play an important role in defending truth and objectivity.

If everyone who saw this today donated $5, we would meet our goal for 2021.

Fighting pseudoscience isn't free.
We are 100% user-supported! Help and donate $5, $20 or whatever you can today with PayPal Logo.png!

Donations so far: $2120Goal: $3500


From RationalWiki
Jump to: navigation, search

This is a repository for scripts created by RationalWiki members or copied from other wikis. To use these, edit your common.js, and add a new line containing

mw.loader.load('path to script');

For example, if you'd like to use User:Nx/Scripts/AutoWIGO.js, you should add


Some of these are also available as gadgets, and can be selected on the "Gadgets" tab in your preferences.

Random Gadget

Go to your Preferences. Tick the gadgets you want to enable, then save.

✅ Adds a link to the user sandbox to the userbar at the top of the page.

Get a new random gadget!



I currently have two scripts.

Quick Sign
This script allows faster signing of comments. Just press ~ and —~~~~ is generated.
Vandal Catcher
Adds a link to RW:Vandal catcher under Recent changes.


To install go to: mypage/common.js.

Add this to install Quick Sign:


Add this to install Vandal Catcher:


If you need help with my scripts, you are free to ask on my user page.


These scripts haven't been updated in years. They do not work properly, use at your own risk.


User:Nx/Scripts/AutoWIGO.js (gadget)
Adds a toolbar button that inserts <vote poll=pollnameX></vote> tags when editing Conservapedia:What is going on at CP, RationalWiki:What is going on in the clogosphere?, RationalWiki:What is going on in the blogosphere? or RationalWiki:What is going on in the world?. X is automatically calculated by scanning the contents of the edit box, finding the largest poll number and incrementing it. This happens every time the page is loaded - including pressing the Show preview and Show changes buttons, and edit conflicts.
User:Phantom Hoover/badwigo.js
Removes WIGOs with votes lower than -5. Credit for creating the script goes to JeevesMkII.


User:Nx/Scripts/Smileybox.js (gadget)
Adds a new button to the editing toolbar; click it to show a second toolbar with smileys. The toolbar shows all the images from Category:Smileys.
User:Nx/Scripts/Smileylist.js (gadget)
An alternative version, adds a smiley list to the edit tools. The list is hidden by default; click Smileys to show it.

Both versions may be active at the same time.

Bot accounts[edit]

This script will warn you if you are a bot and try to edit a talk page. In strict mode, it will also warn you if you try to edit a page not in your userspace. To use strict mode, add "var nx_bw_strict = true;" before the mw.loader.load line. Use it if you often forget to log out of your bot account or remove your bot rights.
Allows quick switching between two accounts. This script will add a "switch" link to the right of the log out link in the upper right corner. Passwords are optionally saved in cookies. For this script to work, add "var botswitch_altacc = "Alt";" before the mw.loader.load line, where Alt is the name of the account you wish to switch to. Warning: if you choose to save your password, anyone who can modify MediaWiki:Common.js or other users' interface files (techs and moderators) could write a malicious script to steal your password. It is therefore better to use the greasemonkey version of this script.
The Greasemonkey version of the Botswitch script. It is more secure, since it uses Greasemonkey's internal storage instead of cookies, which is inaccessible to web pages. To use this, install Greasemonkey, copy the script into a text editor, modify the accounts array at the beginning of the script, and save it as a plain text file with the name "Botswitch.user.js". Then you can drag and drop the file into your browser to install it.


User:Nx/Scripts/Resurrect.js (gadget)
Allows one-click restoration of pages, bypassing Special:Undelete (and the php script execution time limit). A "resurrect" tab will appear to the left of "undelete x edits", clicking it will restore the page. Note that for the tabs to appear, the page must be deleted entirely.
Adds a bot rollback link after normal rollback links, which marks both edits as bot edits.


User:Nx/Scripts/Userrights.js (gadget)
Adds a "User rights" link in the toolbox that allows easy editing of a user's rights.


Adds a convenient "Add comment" link to the bottom of talk page sections.
Adds an edit count below the page title on pages in the User and User talk namespaces.
Hide fake "you have new messages" notices that don't link to your talk page. It has two modes: default and strict. In default mode, the notice will only be hidden if it has a link with the text "new messages" or "last change" that does not point to your talk page. In strict mode, every notice with a link not pointing to your talk page will be hidden. To use strict mode, add "var nx_hfn_strict = true;" before the mw.loader.load line.
Adds color-coding to history.
When viewing pages from the Conservapedia namespace, adds another random page link to the sidebar that selects from the Conservapedia namespace. Indents if randomcpindent is true (var randomcpindent = true;).
Customizable version of the above. To indent, use var randomanyindent = true;. To configure, fill out the randomanyns array with lines like this:
<namespacenumber> : [<url escaped namespace name>, <name that appears in toolbar>, <name that appears in tooltip>  ]
For example:
randomanyns = {
   106 : ['Fun', 'Fun', 'Fun'],
   107 : ['Fun' , 'Fun', 'Fun'],
   2 : ['User_talk', 'talk', 'User talk'],

For script writers[edit]

Code used by more than one script. You'll only need this if you're writing scripts, in that case your scripts should import this one so the user doesn't have to.

See Also[edit]