User:Hoo man/Scripts/Useful links

From Meta, a Wikimedia project coordination wiki
Useful links on my meta contributions page

Useful links gives some useful links on user, user talk and user contribution pages (eg. SUL, editcount or whois). It differs users from IPs and you can add or remove tools.
If you found a bug in this script or if you have a feature request please leave it here or ping me on IRC (hoo).

Installation and customization[edit]

Installation[edit]

To use useful links, you just have to paste this code in your common.js (or into your global.js if you want to use it project wide):

// Gives some useful links on user, user talk and user contribution pages
// by [[m:user:Hoo man]] <http://meta.wikimedia.org/wiki/User:Hoo_man/Scripts/Useful_links>
mw.loader.load('//meta.wikimedia.org/w/index.php?title=User:Hoo_man/useful_links.js&action=raw&ctype=text/javascript');

Customization[edit]

You can customize the tool in many ways (you can eg. completely translate it), here are the most important things you can change. Just append this to your JS file.

To fully disable the script
disable_useful_links = true;
To enable or disable the folded menu, use
if(typeof(usefulLinksConfig) == 'undefined') usefulLinksConfig = {};
usefulLinksConfig.useFoldedMenu = false or true;
To have the links to the tools at another place
if(typeof(usefulLinksConfig) == 'undefined') usefulLinksConfig = {};
usefulLinksConfig.toolLinkMethod = 'FOO';
Can take all values which are possible in addPortletLink

Note: The possibilities to customize the tools can be found in the source code, cause it's a bit tricky and basic JS knowledge is needed to customize them.

Users[edit]