Difference between revisions of "Template:Draft article check/doc"
Jump to navigation
Jump to search
imported>Headbomb m (→Usage: ce) |
imported>Headbomb (→Test Cases: outdated / no longer true) |
||
| Line 16: | Line 16: | ||
In the future, the [[User:HectorMoffet/ShowOnlyToLoggedInUsers.js|ShowOnlyToLoggedInUsers.js script]] could become a [[Wikipedia:Gadget|Gadget]] enabled by default, or its two lines of code could be incorporated into Wikipedia's default javascript file ([[MediaWiki:Common.js]]). | In the future, the [[User:HectorMoffet/ShowOnlyToLoggedInUsers.js|ShowOnlyToLoggedInUsers.js script]] could become a [[Wikipedia:Gadget|Gadget]] enabled by default, or its two lines of code could be incorporated into Wikipedia's default javascript file ([[MediaWiki:Common.js]]). | ||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox|| | <includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox|| | ||
Revision as of 14:46, 26 August 2018
| This is a documentation subpage for Template:Draft article check. It contains usage information, categories and other content that is not part of the original template page. |
DraftChecker is a template to alert editors to the existence of relevant articles or drafts.
- In Draft or Draft_Talk, DraftChecker will check for an Article of the same title.
- In Article_Talk, DraftChecker will check for a Draft of the same title.
- In the Article namespace, Draftchecker will check for a Draft of the same title, but will only show a message if a custom javascript determines the user is logged in.
Usage
{{Draft article check}}
Logged-in editors versus anonymous readers
In order for logged-in editors to view DraftChecker's links in the main Article namespace, two lines of javascript code must be installed: the ShowOnlyToLoggedInUsers.js script.
While DraftChecker is in development, you can install this script by adding the following line to your common.js file:
- importScript('User:HectorMoffet/ShowOnlyToLoggedInUsers.js');
In the future, the ShowOnlyToLoggedInUsers.js script could become a Gadget enabled by default, or its two lines of code could be incorporated into Wikipedia's default javascript file (MediaWiki:Common.js).