I have made a frontend form for the admins where they can check a checkbox for each user and submit the form data by post.

For all the users that are checked, a value should be changed in a field in the database. The slug for this field could be payment_status.

What is a method to update or change the value of a field in the database for a specific user?

I have looked at a question like this: Update some database fields when post is saved

And have been trying with the options methods in wordpress.

But I have trouble finding the way to change the value for the specific user. When this is possible for me, it might not be difficult to convert this into repeating the update process for every checked user in the post data.

  • Have you seen the update_user_meta() WordPress function? – Charles Clarkson Sep 8 '13 at 23:58
  • Thanks, @CharlesClarkson. Why didn't you post this as an answer? – Steeven Sep 14 '13 at 16:18
  • It was too short. Some moderator probably would have moved it to a comment. It has happened before. :) Did it help? – Charles Clarkson Sep 14 '13 at 17:14
  • @CharlesClarkson Yep, that was what I had missed. – Steeven Sep 16 '13 at 19:19

Have you seen the update_user_meta() WordPress function?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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