MemberPress: Send Password Reset Email After Subscription Signup
function mepr_send_password_email_after_signup( $event ) { $user = $event->get_data(); $mepr_options = MeprOptions::fetch(); $wp_user = MeprUtils::get_user_by( ‘id’, $user->ID ); // Creates and stores key (user_activation_key) with default expiration of 1 day add_filter( ‘allow_password_reset’, ‘MeprUser::allow_password_reset’, 99, 2 ); $key = get_password_reset_key($wp_user); remove_filter( ‘allow_password_reset’,…Continue reading