I am trying to hook in to automatically sign-in the user after registration. (using a GravityForms registration form).
None of the hooks seem to be working. I’ve tried: gform_user_registered, user_register, a filtered ‘update_user_metadata’….
Why would this not kill the script after a registration happens?
add_action("user_register", "my_auto_login");
function my_auto_login($user_id) {
die('x');
}
Login after registration seems like it should not be that complicated.
Use the Gravity forms gform_user_registered hook. It fires after the registration and will return the $user_id.