Manual:Redirects
A redirect is a page that contains a line such as: #REDIRECT [[Sandbox]]
.
Such pages serve as "symbolic links" to their target page; in most contexts referring to the redirect page (linking to it, using it as a template, using it as a file name etc.) will have the same result as referring to the target page.
Database edit
Redirects are recorded in the redirect table.
Configuration edit
Configuration settings relevant to redirects include:
- $wgDebugRedirects (defaults to false), displays redirect location instead of actually redirecting to the target URL.
- $wgDisableHardRedirects (defaults to false), disables redirects to special pages and interwiki redirects, which use a 302 and have no "redirected from" link.
- $wgInvalidRedirectTargets (defaults to
array( 'Filepath', 'Mypage', 'Mytalk' )
) is an array of invalid page redirect targets. - $wgMaxRedirectLinksRetrieved (defaults to 500), is the maximum number of links to a redirect page listed on Special:Whatlinkshere/RedirectDestination.
- $wgMaxRedirects (defaults to 1), is the max number of redirects to follow when resolving redirects.
- $wgRedirectSources (defaults to false), is a regular expression to restrict URLs which will be displayed as 'redirected from' links.
Double redirects edit
There are several ways to fix double redirects. fixDoubleRedirects.php is a maintenance script that fulfils that purpose. $wgFixDoubleRedirects is a configuration setting that can take care of such redirects as they are created, but it is only suitable for use on a private wiki because page move vandalism causes problems when it is set to true
.
Code stewardship edit
- Maintained by Unknown or Unassigned[Maintainers page].
- Issue tracker: Phabricator MediaWiki-redirects (Report an issue)