Add custom user profile field to MultiSite registration
-
Hi!
I trying to add a custom field to WP Multisite registration.
I found hooks to display my field but I can’t save its value to user profile, because to do that I need user ID, but user ID, as I assumed does’t exist before user will confirm registration by link in email.
I tryed this code:add_action( 'wpmu_new_user', 'phone_register_extra_fields' ); function phone_register_extra_fields ( $user_id, $password = "", $meta = array() ) { $phone_number = filter_var($_POST['phone_number'], FILTER_SANITIZE_NUMBER_INT); update_user_meta( $user_id, 'phone_number', $phone_number ); }
That is not the only code, but other parts work fine.
How can I save the field value to pending user profile that doesn’t have the ID yet?
Thank you!
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Add custom user profile field to MultiSite registration’ is closed to new replies.