Allows you to point WordPress objects (posts, pages, custom post types) to a URL of your choosing.
Allows users to point WordPress objects (posts, pages, custom post types) to a URL of their choosing, which is particularly useful for injecting non-WordPress content into loops. The object appears normally in any loop output, but visitors to the object will be redirected to the specified URL. The plugin also allows you to choose the type of redirect, either temporary (302), or permanent (301).
Through a filter, the External Permalinks Redux meta box can easily be added to custom post types. There is also a function available for use with WordPress’ add_meta_box
function.
This plugin was originally written for use on WordPress.com VIP. It is inspired by and backwards-compatible with Mark Jaquith’s Page Links To plugin, meaning users can switch between plugins without risk of losing any existing external links.
This plugin is translation-ready.
Using the epr_post_types
filter, one can modify the default array of object types (post
and page
) to include additional custom post types or remove the plugin from one of the default post types.
epr_meta_key_target
– modify the meta key associated with the external URLepr_meta_key_type
– modify the meta key associated with the redirect typeepr_status_codes
– modify array of available status codes used when redirect is issuedget_redirect_data()
method to look up a post ID’s redirect.init
action to ensure that the filters it contains are available to other plugins. Thanks batmoo.epr_post_types
filter discussed in the FAQ.