What is the preferred method for user redirection ?
-
On this page I found 2 fitlers to redirect a user after login.
I tested both (for login/logout) and they both worked. Which one is the best to use ??
I only want to redirect a user to his/her account page (which varies per language), after successful login, not after other actions.
function sd_redirect_to_profile() { return get_permalink( ACCOUNT_PAGE ); } add_filter( 'tml_redirect_url', 'sd_redirect_to_profile' ); // add_filter( 'login_redirect', 'sd_redirect_to_profile' );
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘What is the preferred method for user redirection ?’ is closed to new replies.