• Hello, i have created a new filed in the wp_user table which i’m storing the date of birth of the user. The issue that i have is that is not updating the value and i dont know why. I’m using the wp_get_current_user to get the current user id which is working fine and then i have used the wp_update_user but also the update_user_meta but is not working. here is my code

    wp_update_user( array ( ‘ID’ => $current_user->ID, ‘user_birthday’ => $date) ) ;
    update_user_meta($current_user->ID, ‘user_birthday’,$date) ;

    what i’m doing wrong?

Viewing 1 replies (of 1 total)
  • What are you hooking the function to?

    Use pastebin.com to show me the entire code you are using for adding that field.

Viewing 1 replies (of 1 total)
  • The topic ‘How to update a custom filed in the database’ is closed to new replies.