Gamepedia Help Wiki
(still needed a bit of a rewrite.)
(→‎Notes on usage: fix misleading text (which I wrote); the templates/categories on redirects actually work, but only for the redirect itself)
(25 intermediate revisions by 6 users not shown)
Line 1: Line 1:
'''Redirects''' are used to forward users from one page name to another. They can be useful if a particular article is referred to by multiple names, or has alternative punctuation, capitalization or spellings.
+
'''Redirects''' are pages that forward users from one page name to another. They can be useful if a particular page is referred to by multiple names, or has alternative punctuation, capitalization or spellings.
   
  +
For example, [[AWB]], a commonly-used acronym, redirects to [[AutoWikiBrowser]], the tool's full name.
For example:
 
[https://naturaldoctrine.gamepedia.com/NAtURAL_DOCtRINE_Wiki NAtURAL_DOCtRINE_Wiki] which has official spelling of the game name.
 
   
is a redirect from
+
== Creating or editing a redirect ==
  +
[[File:Pg-options-on-dd menu.png|200px|thumb|Page settings button located in the drop-down menu.]]
  +
[[File:Redirect-edit-menu-visedit.png|300px|thumb|Page settings menu.]]
   
 
To create a new redirect, create a new page (see [[Starting a new page]]) or edit an existing one.
[https://naturaldoctrine.gamepedia.com/NATURAL_DOCTRINE_WIKI NATURAL_DOCTRINE_WIKI] which is the normal name of game page.
 
   
 
Once you are in the Creation window (or Edit window if you edit an existing page), insert the following code into the text entry field:
== Creating a redirect ==
 
Creating a redirect is simple. All one would need to do is create a new page (see [[Starting a new page]]) or edit an existing one.
 
 
Once on the page where you want to set the redirect, click the edit button in the navigation pane and insert the following code into the text entry field.
 
   
 
<nowiki>#REDIRECT [[</nowiki>''pagename''<nowiki>]]</nowiki>
 
<nowiki>#REDIRECT [[</nowiki>''pagename''<nowiki>]]</nowiki>
 
where ''pagename'' is the name of the destination page.
 
where ''pagename'' is the name of the destination page.
   
  +
You can also turn a page into a redirect (or edit an existing redirect) via the visual editor. To do that, follow these steps:
==Important==
 
  +
# Open the visual editor.
The word "redirect" is not case-sensitive, but there must be no text, white space, or empty lines before the "#" symbol and the keyword. The redirect will not function if text of any kind is included before the code.
 
  +
# Click the "Page settings" button located on the "Page options" drop-down menu.
  +
# (''if turning a page into a redirect'') Enable the "Redirect this page to" option and enter the name of the destination page.
  +
# (''if editing an existing redirect'') Change the name of the destination page to the name you want.
   
  +
'''Note''': if you don't know how to view a redirect, see [[#Viewing a redirect|Viewing a redirect]] section below.
Any text or regular content code after the redirect code will be ignored and must be deleted to keep pages clean. If you wanted to keep the original page name to add to a category. You could add a category after the redirect code above. Please see [[Categories]] for more info about adding categories to pages.
 
   
  +
{{Clear}}
==Preview==
 
You should 'preview' (using the button below the Edit window, or use Alt-P) to check that you have entered the correct destination page name. The preview page will not look like the resulting redirect page. It will look like a numbered list, with the destination page in the standard link color as seen in the screenshot below.
 
   
  +
== Notes on usage ==
[[File:redirect-preview.png|400px]]
 
  +
The keyword ''REDIRECT'' is not case-sensitive. Note, however, that there must be no characters before "#" on the page, and no characters between "#" and "REDIRECT". If these conditions are not met, the redirect will not work.
   
  +
There should usually be no more text on the page after the redirect code. Any such text will not affect the target page, and users would have to go to the redirect page to see it. As such, if a template or a [[categories|category]] is designed to be used on redirects, it's fine to put it after the redirect code.
If the ''pagename'' is the correct name of the page you want to redirect to. It will display the name of the page with in any color except red.
 
   
 
== Preview ==
If the name is not correct, it will display the name of the page red, which means that that page doesn't exist. So please ensure that all redirects are all to existing pages.
 
 
[[File:redirect-preview.png|350px|thumb|Preview of a redirect page.]]
  +
  +
To preview a redirect, use the "Show preview" button below the edit window or the '''Alt-Shift-P'''<!-- editor note: different on different browsers or operating systems; however, Firefox and Chrome on Windows and Linux now use Alt+Shift with accesskeys. See https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/accesskey --> key combination. Previewing helps you check that you have entered the correct target page name.
  +
  +
If the page name looks like a working internal link, open that link in another tab to ensure that it's exactly the page you want the redirect to point to.
  +
  +
If the page name looks like a broken internal link, the target page does not exist. Such broken redirects are useless, so please try to avoid creating any.
  +
  +
{{Clear}}
   
 
== Viewing a redirect ==
 
== Viewing a redirect ==
  +
[[File:redirect-view.png|350px|thumb|Example of the note on the target page]]
After you make a redirect, when you go to a page that has the redirect code, it will send it to the page you designated. However, that page will have a slight modification at the top, that tells you that you are being redirected to another page as seen in the picture below.
 
  +
 
After creating a redirect, going to a page with the redirect code will send you to the target page. However, that page will have a slight note at the top, which tells you that you were redirected from another page.
  +
  +
The redirection process does not change the target page in any other way. You can interact with that page like if you visited it directly.
  +
  +
If want to view the redirect page itself, you can do that in a few different ways:
  +
# Click on the link with the name of the redirect in the note mentioned above.
  +
# Use the "[[What links here]]" tool in the [[sidebar]], find the redirect page you need to view and go to that page.
  +
# Edit your browser's address bar to point to the redirect page, but add <code>?redirect=no</code> after the title. For example, to visit https://help.gamepedia.com/AWB this way, use https://help.gamepedia.com/AWB?redirect=no.
   
  +
When you get to the redirect page, you will be able to do anything with it that you can do with any other page.
[[File:redirect-view.png|400px]]
 
   
  +
{{Clear}}
By doing this, you can do all the things that any wiki page allows. You can go to the associated discussion page to discuss the redirect. You can view the history of the page, including a record of the redirect. You can edit the page if the redirect is wrong, and you can revert to an older version to remove the redirect.
 
   
 
== Deleting a redirect ==
 
== Deleting a redirect ==
  +
Assuming you have the [[user rights|user right]] to [[deleting a page|delete pages]], you can delete redirects as well. Redirects are deleted just like any other pages. To delete a redirect, go to the page with the redirect code and open the deletion menu as with other pages.
Deleting a redirect is simple. You can go to the page that has the redirect code, click the navigation list item with the "v" symbol located in the far right of the navigation pane, then click the delete button. Please be sure to follow the procedures at [[Deleting a page]].
 
   
 
== Double redirects ==
 
== Double redirects ==
  +
Double redirects are redirects that point to other redirects. They do not work on Gamepedia, as redirects are followed only once. Turning on [[mw:Manual:$wgMaxRedirects|the setting]] that allows to follow more creates [https://phabricator.wikimedia.org/T32359 major technical issues]. As such, it is not available on Gamepedia.
Double redirects are unnecessary and problematic. They are an infinite loop that shouldn't exist.
 
   
If a double redirect is found, simply remove one of the pages involved and make on one of the pages a redirect to the appropriate page.
+
If you find a double redirect, edit it to point to the final target page directly. If the redirect is not needed, you can instead delete it or mark it for deletion.
   
Unfortunately, after a very significant [[Moving a page|page move]], there could still be remnants of the redirects existing. Use the "what links here" toolbox link to find double redirects to a particular page, or use [[Special:DoubleRedirects]] to find them throughout the whole wiki.
+
[[Moving a page|Moving pages]] can create double redirects, most often if you move a popular page or many pages at once. To find double redirects that point to a specific page, use the "[[What links here]]" tool in the [[sidebar]]. If you want to list all double redirects on the entire wiki, visit [[Special:DoubleRedirects]].
   
  +
If you encounter double redirects often and struggle with fixing them, you can use [[Pywikibot]] to automate this process. However, PWB is difficult to set up.
== A redirect to a page in the category namespace ==
 
To redirect to a category page and prevent the redirect appearing in this category, precede the word "Category" with a colon, otherwise the redirect page will also be categorized to the category itself:
 
<nowiki>#REDIRECT [[:Category:Glossary]]</nowiki>
 
   
  +
== Moving pages without creating redirects ==
== Suppressing a redirect ==
 
Users with the ''suppressredirect'' right may move a page without creating a redirect. You can check what rights are available to various user groups on [[Special:UserGroupRights]]. By default, all [[Gamepedia Help Wiki:Autoconfirmed users|autoconfirmed users]] have the ability to move a page without leaving a redirect.
+
Users with the ''suppressredirect'' [[User rights|right]] can move a page without creating a redirect. By default, all [[Gamepedia Help Wiki:Autoconfirmed users|autoconfirmed users]] have this right.
   
 
[[Category:Advanced editing]]
 
[[Category:Advanced editing]]
   
 
[[fr:Redirections]]
 
[[fr:Redirections]]
  +
[[ru:Перенаправления]]
  +
[[tr:Yönlendirmeler]]

Revision as of 19:50, 2 June 2020

Redirects are pages that forward users from one page name to another. They can be useful if a particular page is referred to by multiple names, or has alternative punctuation, capitalization or spellings.

For example, AWB, a commonly-used acronym, redirects to AutoWikiBrowser, the tool's full name.

Creating or editing a redirect

Pg-options-on-dd menu

Page settings button located in the drop-down menu.

Redirect-edit-menu-visedit

Page settings menu.

To create a new redirect, create a new page (see Starting a new page) or edit an existing one.

Once you are in the Creation window (or Edit window if you edit an existing page), insert the following code into the text entry field:

#REDIRECT [[pagename]]

where pagename is the name of the destination page.

You can also turn a page into a redirect (or edit an existing redirect) via the visual editor. To do that, follow these steps:

  1. Open the visual editor.
  2. Click the "Page settings" button located on the "Page options" drop-down menu.
  3. (if turning a page into a redirect) Enable the "Redirect this page to" option and enter the name of the destination page.
  4. (if editing an existing redirect) Change the name of the destination page to the name you want.

Note: if you don't know how to view a redirect, see Viewing a redirect section below.

Notes on usage

The keyword REDIRECT is not case-sensitive. Note, however, that there must be no characters before "#" on the page, and no characters between "#" and "REDIRECT". If these conditions are not met, the redirect will not work.

There should usually be no more text on the page after the redirect code. Any such text will not affect the target page, and users would have to go to the redirect page to see it. As such, if a template or a category is designed to be used on redirects, it's fine to put it after the redirect code.

Preview

Redirect-preview

Preview of a redirect page.

To preview a redirect, use the "Show preview" button below the edit window or the Alt-Shift-P key combination. Previewing helps you check that you have entered the correct target page name.

If the page name looks like a working internal link, open that link in another tab to ensure that it's exactly the page you want the redirect to point to.

If the page name looks like a broken internal link, the target page does not exist. Such broken redirects are useless, so please try to avoid creating any.

Viewing a redirect

Redirect-view

Example of the note on the target page

After creating a redirect, going to a page with the redirect code will send you to the target page. However, that page will have a slight note at the top, which tells you that you were redirected from another page.

The redirection process does not change the target page in any other way. You can interact with that page like if you visited it directly.

If want to view the redirect page itself, you can do that in a few different ways:

  1. Click on the link with the name of the redirect in the note mentioned above.
  2. Use the "What links here" tool in the sidebar, find the redirect page you need to view and go to that page.
  3. Edit your browser's address bar to point to the redirect page, but add ?redirect=no after the title. For example, to visit https://help.gamepedia.com/AWB this way, use https://help.gamepedia.com/AWB?redirect=no.

When you get to the redirect page, you will be able to do anything with it that you can do with any other page.

Deleting a redirect

Assuming you have the user right to delete pages, you can delete redirects as well. Redirects are deleted just like any other pages. To delete a redirect, go to the page with the redirect code and open the deletion menu as with other pages.

Double redirects

Double redirects are redirects that point to other redirects. They do not work on Gamepedia, as redirects are followed only once. Turning on the setting that allows to follow more creates major technical issues. As such, it is not available on Gamepedia.

If you find a double redirect, edit it to point to the final target page directly. If the redirect is not needed, you can instead delete it or mark it for deletion.

Moving pages can create double redirects, most often if you move a popular page or many pages at once. To find double redirects that point to a specific page, use the "What links here" tool in the sidebar. If you want to list all double redirects on the entire wiki, visit Special:DoubleRedirects.

If you encounter double redirects often and struggle with fixing them, you can use Pywikibot to automate this process. However, PWB is difficult to set up.

Moving pages without creating redirects

Users with the suppressredirect right can move a page without creating a redirect. By default, all autoconfirmed users have this right.