This tool is designed primarily with Wikia wikis in mind, but should work for many wikis by default, and has some settings to handle special cases for certain non-wikia mwikis (such as "&scriptdir=" below). When adding non-wikia wikis, it's important to note that this script is designed for MediaWiki wikis, and requires the Mediawiki Api to be enabled on a wiki to run.
All that's truly need after the script is installed is a div with the "rc-content-multiple"
class and a bullet list with the link of the wiki's domain (the div will need to be added via source mode). Duplicate entries are ignored. Example:
<div class="rc-content-multiple"> *runescape.wikia.com *wowwiki.com *dev.wikia.com </div>
Note: Do not include
http:// before the url.
Inspired by AjaxRC, an "auto-refresh" option is available, that when ticked will cause the list to be refreshed every 60 seconds. A cookie is used to store the setting of the checkbox once clicked.
If your language is supported, it will automatically be used based on the language in your settings / wiki language. See more on translation stuff below.
Note: Multiple instances (DIVs) of the script may be run on the same page (for whatever reason you may wish), but keep in mind some of the additional parameters below are only checked on the first instance (data-lang, data-hiderail, data-loaddelay).
While the above works and that's all that may be needed, there are also many other additional parameters that can be added, in 3 ways: 1 that effects every RCM, 1 that effects every wiki on a specific RCM list, and one that effects a specific wiki.
This effects every RCM on the page. Currently the only url variables accepted are those used by a standard RecentChanges page. See more at RC Params below.
These effect every wiki / the script as a whole.
|data-params=||RC url params||-||The exact params you would use on Special:RecentChanges, without the "?" after the title (ex: |
|data-hideusers=||Comma separated list||-||A list of users you like to hide the edits of on all wikis, separated with commas. Do not include "User:", and whitespace may be included before/after the commas (white space/underscores in names is required).|
|data-timezone=||string||utc||By default this script lists dates in UTC. If this attribute is set to "local", the times listed will be based on the local time as determined by the web browser.|
|data-autorefresh=||Whole number||60||The number of seconds for the script to wait to auto-refresh (if the auto-fresh box is checked). Any number above 0 is valid. Note that the time starts after a refresh has completely finished and all results have been added to the screen.|
|data-lang=||Country Code||auto-detect||This is the language used when translating text in the script. By default, this script uses the language set in your user settings (or wiki language if anon) to display a language if supported, or "en" if the language if not supported (except for RecentChanges text, which is taken directly from the server and should always be supported). For those whose language isn't supported but don't wish to use English as the translation, set this to a 2 letter language code ("fr", "pl", etc).|
|data-onlyshowusers=||Comma separated list||-||If a list of users exists, the script will only show edits by these user(s), hiding all non-specified user edits. "hideusers" (both dataset (above) and wiki-specific (below)) takes precedent. Do not include "User:", and whitespace may be included before/after the commas (white space/underscores in names is required).|
|data-hiderail=||Boolean||true||By default any page that includes a ".rc-content-multiple" div will have it's rail hidden (so it takes up whole page, like normal RC). This parameter is simply a way to reverse this, if desired, when this parameter is equal to "false".|
|data-loaddelay=||Number||10||The time (in milliseconds) to wait between loading wikis. Only time this is needed to be increased is when loading a large number of wikis (100+) to avoid load limit and being blocked temporarily.|
|data-extraLoadingEnabled=||Boolean||true|| Since not all information can be retrieved in the initial call (since it requires the initial information), it's loaded after all content is added to the screen. Since this is not strictly needed, this offers a way to turn it off (possibly to limit server calls or to save on bandwidth). Currently this is required for:
datasets go directly inside the div, like so:
<div class="rc-content-multiple" data-params="hidemyself=1&days=10&limit=50" data-hideusers="TestUser,My awesome username,ILikePIE"> *list of wikis </div>
On List ItemsEdit
Every item on the list must start with the wiki's base url, in the format "name.wikia.com" (or or lang.name.wikia.com, or "wikiname.com" (or other top level domain) if the wiki doesn't have "wikia" in it). Do not include "http://", and anything after or including the first "/" at the root.
These allow you to customize a specific wiki's results, instead of requiring every wiki listed to use the same options.
Each list item may have parameters added after it in the format "¶mname=" to add additional functionality for how that wiki is displayed / loaded.
|¶ms=||RC url params||-||Same as data-params, except "&"s must be turned into commas (","), and "="s into colons (":"). See also RC Params below.|
|&hideusers=||Comma separated list||-||Much like the "data-hideusers=" above, this accepts a comma-separated list of users, but instead they are only hidden for the specified wiki. Do not include "User:".|
|&onlyshowusers=||Comma separated list||-||Much like the "data-onlyshowusers=" above, this accepts a comma-separated list of users, but instead it only triggers for the specified wiki. Do not include "User:".|
|Special cases for properly displaying wikis|
|&scriptdir=||text||-||(for non-wikia wikis) The sub-directory of the wiki scripts should access. Ending "/" should not be included. By default the script checks the root of the domain (as this is how it is on Wikia), but for some wikis it may be something else (popular directories are "/w" and "/wiki"). An easy way to find it is to enter "|
|&favicon=||URL (without http://)||-||Replaces the favicon used for the wiki with the one specified. Simply include the full url without the "http://". Intended for wikis that don't have favicons or if the default one is too similar to another wiki on the list.|
<div class="rc-content-multiple"> *fewfre.wikia.com&hideusers=Fewfre,FewBot *wiki.guildwars2.com&favicon=wiki.guildwars2.com/images/thumb/d/df/GW2Logo_new.png/180px-GW2Logo_new.png *pixelmonmod.com&scriptdir=wiki¶ms=hidemyself:1,limit:5 </div>
Offers a way to tweak "data-params=" options in real-time. These changes are not saved, so one of the above methods should be used if you want the change to persist after a page refresh / closure.
To help emulate Special:RecentChanges as much as possible, this script accepts RC-style url params (used as explained above). There are multiple params, as explained below. Please not that these effect each wiki individually (so a limit of 50 for 4 wikis is actually a limit of 200).
There are 4 ways to specify params in the script. If more than one is specified, they will "fall through", with the more specific one overwriting the less specific one (ex: "¶ms" is more specific than "data-params"), but only if they both change the same thing (such as "days"). The order of specificity is as such:
- [Default values]
- URL variables - same as a normal RecentChanges page.
- Options panel (run-time options)
- ¶ms (note that the "options panel" will not overwrite these)
Note that for "true/false" boolean switches, "0" is false, and "1" is true.
|limit||50||This can be any whole number between 0-500. (may be less depending on "days")|
|days||7||Number of days. (may be less depending on "limit")|
|Hides edits that were marked as "minor"|
|Hides edits done by a bot|
|Hides edits done by anonymous users.|
|Hides edits done by logged-in users.|
|Hides edits done by the account you are logged in as. Note: "hide-users=" will override this (even when using options panel). Also note that on external wikis this script assumes you have the same username. Use "&hide-users=" to hide your name, and ¶ms=hidemyself:0 to show the user who has your wikia username (if you have one).|
|Doesn't group edits, instead showing each edit in the order they were done. Note: Isn't supported on a wiki-per-wiki basis (all or nothing).|
|from, namespace, invert, associated, tagfilter, hidewikidata, and any others not listed.|
Feel free to request support for an unsupported param to be added if you need it; all should be more or less possible.
This script is translated in two separate ways:
- Script Text ("TEXT" in code) - normal translation stuff like any other script that needs to be updated by hand.
- RecentChanges Text ("RC_TEXT" in code) - this is done automatically, by loading the text normally found in Special:RecentChanges from the server. Any language normally supported by Wikia should be supported by this script for this type of translation.
- 14 February 2015 - Alpha finished (followed by break).
- 22-27 May 2015 - Beta finished.
- 28 June 2015 - Script published.
26 July 2015 - MediaWiki API rewrite - V1.1.0Edit
The main purposes of this rewrite were to:
- Add automatic translation support for RecentChanges text.
- Remove YQL dependency (info taken directly from wiki via API). Also results in faster loading.
- Using API support, add more Special:RecentChanges support (minor edits marked, more control on content ("days", "limit", "showbots", etc)).
- Rewrite code to be a bit more efficient.
- Important notes:
- "&subdir" removed, and "&scriptdir" added (may be necessary for non-wikia wikis, see above). ex:
- "data-params" now offers much more support. "days" and "limit" now work up to same amount as normal for each wiki on the list. As such this should be limited to a few days / a lower limit to avoid loading potentially thousands of changes. Individual wikis can have these limits modified using "¶ms"
- "&subdir" removed, and "&scriptdir" added (may be necessary for non-wikia wikis, see above). ex:
- Changed translating to use the exact i18n info from Wikia's github for RC_TEXT. Loads RC_TEXT from the server based on your language.
- Boards/walls now also check for [ restore, delete, remove ] for "replies" instead of assuming it's the actual thread.
- All (normal) RecentChanges params supported, except "
hideenhanced", "from", and viewing a select namespace.
- Bot edits can now be shown (off by default), and "minor" edits are now marked.
- gApp instance turned into the RecentChangesMultiple class (to potentially run multiple for whatever reason, plus I prefer "traditional" OO class structures)
- As such, #rc-content-multiple id should now be a .rc-content-multiple class to allow for multiple instances (although using ids is still supported)
- Additional Special:RecentChanges CSS classes used.
- Rewrote RC / RCList objects (to bring a little more inline with how it's structure in mw system)
- New "WikiData" class for storing wiki-specific data in a more understandable way, while also providing helper methods
- "Red links" for page that don't exist won't show up on most logs, since this information would have to be retrieved individually for every page.
- Patrolling not supported at this time. This is due to mediawiki security that prevents patrol info from being accessed unless authorized (severely breaking if not). Even if rights exist, the info cannot be accessed due to login being required on that wiki which is not available via cross-domain (browser security).
- Logs may do weird things on "rare" cases (like staff-only actions and rare extension-only actions). Support for these can be added, but aren't in by default since each needs to be manually checked for each type (and sometimes each specific action).
- (Rights log) - the rights will be listed using their "id" instead of a translation of the user group. So it'll be things like "sysop". Not all wikis have same groups, so getting translations from each wiki is more of a burden than it's worth.
- This script retrieves RecentChanges translations directly from the server. As such translations might differ when using non-Wikia wikis. If the loading failed enough times, it'll just default to English text.
- "http://" shouldn't be used in this script to avoid it automatically becoming a link (makes it annoying to deal with), and shows up on Special:LinkSearch as a page with an external link (may be undesirable).
- Designed for Wikia wikis, but should work for any wiki (assuming it's not too out-of-date).
- Some non-Wikia wikis simply do not seem to work, due to how they are setup (MediaWiki version is to old, API disabled, etc).
- The script should be run using code.2.js. Although no longer supported, the original atom-feed version can be found at /code.js, with documentation for it found here.
- All wikis in the script must:
- Be Mediawiki wikis (Version 1.16+)
- Have the Mediawiki Api available.
- Browser that supports various aspects of ECMAScript5 (any up-to-date browser will basically be fine).
- The script has to run on a Wikia wiki (to make sure it have access to things like the code for collapsing lists).