WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I update user info using wp_update_user function. I also need to update the table wp_bp_xprofile_data. Is there any function, where I can update data on wp_bp_xprofile_data table?

share|improve this question

closed as off-topic by toscho Aug 2 '14 at 20:53

This question appears to be off-topic. The users who voted to close gave this specific reason:

If this question can be reworded to fit the rules in the help center, please edit the question.

1  
Stupid that buddy press questions are closed as off topic. Google brought me here, and it provided the answer I needed. This is exactly what Stack Exchange sites are for, and if questions about one of the most popular WordPress plugins can't be asked in WordPress Dev, where is it supposed to be asked? – lwitzel Mar 1 at 0:12
    
I had not noticed that they closed this thread as off-topic. Strange! But fortunately by that time the answer has been already answered. – Debiprasad Mar 2 at 5:35
    
All third party plugins are off-topic. – Debiprasad Mar 2 at 5:40
up vote 9 down vote accepted

This is how I would update a field named 'Address':

function updateAddress() {

    global $current_user;
    get_currentuserinfo();

    $newAddress = '123 New Street';

    xprofile_set_field_data('Address', $current_user->id,  $newAddress);

}
share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.