Template:Redirect/doc

Description
This template is mainly meant to be used as a substitute for the "#REDIRECT" syntax. The difference is that it adds the proper redirect categories with the proper sort key.

It is also used on the redirect pages to provide the proper redirect categories. You don't have to bother about this if you use the first point.

General Use
To use this template as a replacement for the "#REDIRECT" syntax, simply replace the content of a page with

where &lt;destination&gt; is the name of the page targeted by the redirect, without the link brackets.

Note that the template must be substituted (i.e., the "subst:" part is fundamental), or it won't work.

For exemple, if you want to redirect a page to Portgas D. Ace, replace its contents by Portgas D. Ace It puts the redirect page to Category:Redirects, with "Portgas D. Ace" as a sort key.

Authorized Redirects
In general, redirects are not allowed on articles. However, there are exceptions, when the redirect is an independant topic that could be an article by itself, but isn't for some reason (generally because there is not enough material for it to be an independant article).

To mark a redirect as "authorized", simply use the following syntax:

For example, the Humandrill article is a redirect to the Humandrill part of the Animal Species article; it was created with Animal Species/Summit War Saga#Humandrill It puts the redirect page to Category:Authorized Redirects, with "Humandrill" as a sort key (and not "Animal Species/Summit War Saga#Humandrill", as it would have been in the general case).

The idea of authorized redirects has an issue: the MediaWiki software cannot cope with double redirects, so it's impossible to use an authorized redirect exactly as if it was a standard article. For example, we cannot redirect Mandrill to Humandrill directly, as it would create a double redirect.

In order to keep a trace of all those redirects that should point to an authorized redirect (but do not because of software limitations), they should be categorized separately. It is easy to do with the redirect template:

Here, the target parameter is used to provide the name of the authorized redirect that would be the target of the current redirect, if not for software limitations.

For example, any redirect to Humandrill, such as "Mandrill", "Mandrills", "Humandrills", "Fighting Monkeys" or whatnot were created (or could be created) with Animal Species/Summit War Saga#Humandrill It puts the redirect page to Category:Redirects to Authorized Redirects, with "Humandrill" as a sort key: this way it is easy to find all redirects to an authorized redirect, simply by browsing the category.

Use on Redirect Pages
This is not meant to be used directly, since the substitution automatically puts the correct parameters. Here is the info anyway:
 * parameter subst=no indicates the no-substitution usage.
 * parameter type= indicates the type of the redirect: standard, authorized, or double (i.e., meant to point to an authorized redirect)
 * parameter target= indicates the targeted authorized redirect, in case type=double.