How do I redirect a post url to a custom url?
Well, actually WordPress provides wp redirect function. And here is a small plugin I’ve used a while back <?php $redirect_meta_key = ‘redirect_to’; add_action(‘template_redirect’, ‘redirect_this’); function redirect_this($nothing) { global $wp_query, $redirect_meta_key; if(is_single() || is_page()) { $redirect = get_post_meta($wp_query->post->ID, $redirect_meta_key, true); if(” != $redirect) { wp_redirect($redirect); header(“Status: 302”); exit; } } } ?> No all you have … Read more