Snippets

Dan Bochichio BuddyPress Login / Logout Redirect

Created by Dan Bochichio last modified
function custom_login_redirect_to($user_login, $user) {
	bp_core_redirect( get_option('siteurl') . "/dashboard" );
}
add_action('wp_login', 'custom_login_redirect_to', 10, 2);


add_action('wp_logout','auto_redirect_after_logout');
function auto_redirect_after_logout(){
  wp_redirect( home_url() );
  exit();
}

Comments (0)