Skip to content

Instantly share code, notes, and snippets.

@alessandrotesoro
Created November 19, 2018 16:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alessandrotesoro/890fc4a314f75f53c4065e2c9ab158c6 to your computer and use it in GitHub Desktop.
Save alessandrotesoro/890fc4a314f75f53c4065e2c9ab158c6 to your computer and use it in GitHub Desktop.
function wpum_my_redirect() {
if ( is_page( wpum_get_core_page_id('register') ) && is_user_logged_in() ) {
wp_safe_redirect( get_permalink( 9999 ) );
exit;
}
}
add_action( 'template_redirect', 'wpum_my_redirect' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment