I re-added this in the edit.php inside the while ( bp_profile_fields() ) do_action( 'xprofile_updated_profile', bp_displayed_user_id(), bp_get_the_profile_field_id(), trim(strip_tags(bp_get_the_profile_field_value())) );
Now… Do you know what is the hook do to upon user registration?
I read that page before. Still nothing’s echoed.
I removed all my lines from edit.php there’s just functions.php with your above code, but where does do_action() go now? Still don’t get how $posted_field_ids is populated
Can’t EDIT my posts on the forums anymore…
So my question is: what’s this $posted_field_ids variable? How does it get populated; it’s always NULL, same as $_POST (I’m in edit.php)
Thanks @shanebp but I’m fairly new to WP and BP. This is what I do:
1. edit.php: At the end of file just after “do_action( ‘bp_after_profile_edit_content’ );”
I’m adding your line: do_action( 'xprofile_updated_profile', bp_displayed_user_id(), $posted_field_ids, $errors );
2. functions.php:
function hook_bp_profileupdate( $ids, $errors ) {
// CALL API AND POST THE IDs
print_r( $ids );
}
add_action( 'xprofile_updated_profile', 'hook_bp_profileupdate', 0, 2 );