/** * Add fields to user profile */ function wpcf_admin_user_profile_save_hook($user_id) { if (!current_user_can('edit_user', $user_id)) { return false; } require_once WPCF_EMBEDDED_INC_ABSPATH . '/fields.php'; require_once WPCF_EMBEDDED_INC_ABSPATH . '/fields-post.php'; require_once WPCF_EMBEDDED_INC_ABSPATH . '/usermeta-post.php'; wpcf_admin_userprofilesave_init($user_id); }
/** * Hooks to 'user_register' * @param type $user_id */ function wpcf_usermets_add_user_submit($user_id) { if (isset($_POST['wpcf'])) { wpcf_admin_userprofilesave_init($user_id); } }