Created
April 8, 2016 14:47
-
-
Save strangerstudios/165e2f65e8764c7a1686452fd5c9705e to your computer and use it in GitHub Desktop.
Example of using the pmpro_confirmation_url filter to change the PMPro confirmation page for new users.
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
function my_pmpro_confirmation_url($url, $user_id, $level) { | |
$already_member = get_user_meta($user_id, 'already_member', true); | |
if(!$already_member) { | |
update_user_meta($user_id, 'already_member', 1); | |
$url = home_url('/my-dashboard'); | |
} | |
return $url; | |
} | |
add_filter('pmpro_confirmation_url', 'my_pmpro_confirmation_url'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment