Allow plugins to change the redirect on post/page publishing/submitting. Fixes #10929 props johnjosephbachir and johnbillion.
git-svn-id: http://svn.automattic.com/wordpress/trunk@12260 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
908c4a24ca
commit
b912aa2012
|
@ -64,7 +64,7 @@ function redirect_page($page_ID) {
|
|||
$location = add_query_arg( 'message', 1, get_edit_post_link( $page_ID, 'url' ) );
|
||||
}
|
||||
|
||||
wp_redirect($location);
|
||||
wp_redirect( apply_filters( 'redirect_page_location', $location, $page_ID ) );
|
||||
}
|
||||
|
||||
if (isset($_POST['deletepost']))
|
||||
|
|
|
@ -69,7 +69,7 @@ function redirect_post($post_ID = '') {
|
|||
$location = add_query_arg( 'message', 4, get_edit_post_link( $post_ID, 'url' ) );
|
||||
}
|
||||
|
||||
wp_redirect( $location );
|
||||
wp_redirect( apply_filters( 'redirect_post_location', $location, $post_ID ) );
|
||||
}
|
||||
|
||||
if ( isset( $_POST['deletepost'] ) )
|
||||
|
|
Loading…
Reference in New Issue