User:Chlod/Scripts/GlobalUserToolbox
| Author | Chlod |
|---|---|
| Status | Release |
| Updated | February 8, 2020 |
| Browsers | Firefox (but likely works on all browsers) |
| Skins | Vector |
| Source | User:Chlod/Scripts/GlobalUserToolbox.js |
Global User Toolbox (GUT) is a script that adds the {{User toolbox}} template to all pages in the "User" and "User talk" namespaces.
Installation
To install the script, add this to your common.js file.
mw.loader.load( '/w/index.php?title=User:Chlod/Scripts/GlobalUserToolbox.js&action=raw&ctype=text/javascript' ); // Backlink: [[User:Chlod/Scripts/GlobalUserToolbox.js]]
Features
The following options can be configured. You can change them by setting a variable named "gutOptions" to an object with the configuration keys you want.
| Key | Type | Default | Description |
|---|---|---|---|
| include_userpages | boolean (true/false) | true | Include all pages (excluding subpages) under the "User" namespace. |
| include_talkpages | boolean (true/false) | true | Include all pages (excluding subpages) under the "User talk" namespace. |
| include_subpages | boolean (true/false) | true | Include all pages (including subpages) under the "User" namespace. |
| include_talksubpages | boolean (true/false) | true | Include all pages (including subpages) under the "User talk" namespace. |
| insert_at_top | boolean (true/false) | true | Insert the user toolbox at the top of the page? (Inserted at bottom, if false.) |
| ignore_existing | boolean (true/false) | true | Disable adding a toolbox if there is already a toolbox for that user on the page. |
| start_collapsed | boolean (true/false) | true | Create the toolbox collapsed (if collapsible.) |
These settings can be applied like so:
// The variable name must ALWAYS be gutOptions.
var gutOptions = {
"insert_at_top": false,
"ignore_existing": false
};
mw.loader.load( '/w/index.php?title=User:Chlod/Scripts/GlobalUserToolbox.js&action=raw&ctype=text/javascript' ); // Backlink: [[User:Chlod/Scripts/GlobalUserToolbox.js]]
Source
The source can be found at User:Chlod/Scripts/GlobalUserToolbox.js. Like all Wikipedia pages, the license is CC BY-SA 3.0.
Discussion
You may visit my talk page if you have any concerns.
Content Disclaimer
Informasi ini disarikan dari Wikipedia dan disajikan kembali untuk tujuan edukasi. Konten tersedia di bawah lisensi CC BY-SA 3.0. Kami tidak bertanggung jawab atas ketidakakuratan data yang bersumber dari kontribusi publik tersebut.
- The information displayed on this website is sourced in part or in whole from Wikipedia and has been adapted for the purpose of restating it. We strive to provide accurate and relevant information, however:
- There is no guarantee of absolute accuracy. Wikipedia is an open, collaborative project that can be edited by anyone, so information is subject to change.
- It is not intended to constitute professional advice. The content displayed is for informational and educational purposes only. For important decisions (e.g., medical, legal, or financial), please consult a professional.
- Content copyright. Wikipedia is licensed under the Creative Commons Attribution-ShareAlike License (CC BY-SA). This means that content may be reused with appropriate attribution and shared under a similar license.
- Responsible use. Any risk arising from the use of information from this website is entirely the responsibility of the user.