Created
March 2, 2012 15:25
-
-
Save mikejolley/1959165 to your computer and use it in GitHub Desktop.
WooCommerce - Change login redirect
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* goes in theme functions.php or a custom plugin | |
* | |
* By default login goes to my account | |
**/ | |
add_filter('woocommerce_login_widget_redirect', 'custom_login_redirect'); | |
function custom_login_redirect( $redirect_to ) { | |
$redirect_to = 'http://anypage.com'; | |
} |
How about redirecting to last visited page?
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It would be better: