Redirect pages and posts to other locations.
This lightweight plugin adds a meta box to your page and post screens. You can enter a new destination URL to which the page will be redirected.
speedy-page-redirect
folder to your /wp-content/plugins/
directory.speedy-page-redirect
folder to your /wp-content/plugins/
directory.Yes. In the “Destination URL” field, just start your URL with a forward slash instead of “http://”. The site address, set in Settings > General, will automatically be prepended.
Yes. By default “page”, “post” and all public custom post types are taken into account. You can customize this selection via the gdd_spr_post_types
filter. It should return an array with the applicable post types.
Example:
add_filter( 'gdd_spr_post_types', 'gdd_spr_post_types' ); function gdd_spr_post_types( $post_types ) { // Disable redirection for the "book" post type unset( $post_types['book'] ); return $post_types; }
Yes. By default you can choose from a 301 (permanent) and 302 (temporary) redirect. To customize this list, a filter called gdd_spr_statuses
is available. It should return an array with the keys corresponding to the HTTP response codes. The array values are descriptions used in the dropdown list.
Note: if the statuses list only contains a single entry, the dropdown list is automatically omitted from the meta box.
Example:
add_filter( 'gdd_spr_statuses', 'gdd_spr_statuses' ); function gdd_spr_statuses( $statuses ) { // Remove temporary redirection from the list unset( $statuses[302] ); return $statuses; }