User:PerfektesChaos/js/userspaceLinks
JavaScript gadget to put toolbox links on pages related to a particular user.
Currently there is only one feature (Subpages). Some more will be added later, when migrated labsconsole: tools are available.
Usage
edit- If your project has registered this as a gadget, just activate on your Preferences page.
- Otherwise include the following lines into your common.js or skin dependant like vector.js:
mw.loader.load("//www.mediawiki.org/w/index.php?title=User:PerfektesChaos/js/userspaceLinks/r.js&action=raw&bcache=1&maxage=86400&ctype=text/javascript",
"text/javascript");
- If you are blocking scripts from sites other than your local Wiki you might need to put www.mediawiki.org on the whitelist.
- The gadget works also with non-WMF sites using MediaWiki 1.18 or higher.
Effects
editThe pages related to a particular user are:
- User namespace
- User talk namespace
- Special:Contributions of a user.
- Special:Listfiles of a user.
Subpages
editA link is added to the portlet toolbox (usually on left hand side). It opens the list of all subpages related to this user.
If called from a user subpage itself, only this and deeper subpages are shown.
Special:Prefixindex is target here and cannot point to itself.
Codes
editSource code |
|
ResourceLoader |
|
Namespaces | -1 , 2 , 3
|
mw.libs
|
userspaceLinks
|
Other languages
editThis gadget is prepared for multilingual support.
- If you like a version in your own language, please forward translations to me:
- This documentation page.
- The
URSLI.texts
mapping on top of source code. - Further ISO 639 language codes your translation might support.