Redirection
Support This Plugin!
While this software is being provided free to use, it takes considerable time to develop and support. If you do find it particularly useful or want to request a feature then consider donating money as an incentive for me to carry on developing it.
Thanks!
Redirection is a WordPress plugin to manage 301 redirections, keep track of 404 errors, and generally tidy up any loose ends your site may have. This is particularly useful if you are migrating pages from an old website, or are changing the directory of your WordPress installation.
New features include:
Existing features include:
NOTE: If you are upgrading from a previous version then please visit the Redirection options page at least once.
Get the Flash Player to see this movie.
Version History
Installation
Installation is just like any WordPress plugin:
redirection directory to /wp-content/plugins on your server Activate the plugin Configure options from Manage » RedirectionNote that you must have a permalinks structure setup through WordPress.
You can find full details of installing a plugin on the plugin installation page.
Usage
A redirection is a way for the web server to tell the browser that a particular page is no longer at the current address, and to indicate where it should go to find the new page. The Redirection plugin allows you to create several types of redirections:
In addition you can also create specific 404 pages, as well as 'pass-through' pages.
A redirection is created from the Redirection screen in the administration panel:
You can add as many redirections as you want, and redirections will be displayed in a colourful list:
This list can be sorted by any attribute, and can even be manually arranged by dragging and dropping the type. You can save the current order by pressing the 'save order' link. Redirections are processed according to their position, so this will be useful should you require a specific order. You may get a performance benefit by putting your most used redirections at the start of the list.
Pass-Through
Pass-through pages provide the same features as Apache's mod_rewrite, but without requiring either Apache or mod_rewrite, and without requiring .htaccess files. A pass-through URL is a page where the content is retrieved from some other location, but the URL does not change. This other location can be another WordPress post, a file, or even another website.
While you can specify another website as the target for a pass-through page, it should be noted that the contents for this are retrieved by your server, and it is likely that your host will not be very appreciative.
Regular Expressions
Regular expressions can be enabled for all redirections and allow you to specify a pattern, rather than an exact URL. A pattern has the potential to match more than one URL, and so regular expressions give you the ability of reducing a large set of redirected URLs to a small number of patterns.
Explaining regular expressions is beyond the scope of this documentation, and you can find more details elsewhere on the internet.
A couple of examples:
/blog/(.*) => /$1
This will match any URL that starts with /blog/, and will redirect it to the same URL but without /blog/. For example, /blog/2006/10/01/mypost will be redirected to /2006/10/01/mypost.
/2006/month_\d+/(.*) => /2006/$1/$2
This will match any URL that starts /2006/month_, and is then followed by a number. This will be redirected to the same URL, but without month_. For example, /2006/month_1/something will be redirected to /2006/1/something.
To replace a single dash in a URL with a space:
/tags/(.*?)-(.*?) => /tags/$1%20$2
Redirection Methods
Redirection provides ways of adding conditions into a redirection:
Redirecting based on referrer
For example, you want to redirect users for /feed/ to /feed2/, unless the user comes from Feedburner. To achieve this you must first create a new redirection item using 'redirect based on referrer'. Once the redirection has been created you can edit it and change the details as follows:
/feed/ Referrer - ^feedburner.*$ Referrer regex - yes URL not from referrer - /feed2/This sets up a rule whereby if the referrer does not match then the user is redirected to /feed2/, otherwise no redirection occurs.
Logs & 404 errors
Every redirected URL is recorded, along with data about the user that visited it. You can view these logs from the administration pages.
Further log details can be obtained by clicking the date of the log entry. On the 404 error page you can also click the plus icon to copy the URL, ready to create a new redirection.
Options
The options page allows you to configure special features of the Redirection plugin:
index.php/index.html - Automatically strip index.php and index.html from URLs Root domain - Automatically remove or add 'www' to a URLDevelopers
Redirection exposes two WordPress filters, allowing you to add additional redirection events through your own plugins:
redirection_first - Passed the current URL before any other redirections redirection_last - Passed the current URL after all other redirectionsYou can manually redirect, or you can return a Redirection_Item (examination of the code should be sufficient information).
Support
Please direct all support questions to the Redirection support forum. Any support questions left on this page may not be answered.
Bugs & New Features
A full list of all bugs can be found in the Redirection issue tracker.
A full list of all requested features can be found in the Redirection feature tracker.
Help me to save time by reading these instructions!
Please report bugs in the Redirection issue tracker.
Please make feature suggestions in the Redirection feature tracker.
Please direct all support questions to the Redirection support forum.






