Is there an straight-forward example anywhere of using wp_update_post() to edit post_meta on the front end? I have not been able to find any good learning resources.

What I want to do is display post meta in an input field and when a user clicks submit trigger wp_update_post();.

post meta in input field with save button


1 Answer 1


wp_update_post isn't used for updating custom fields (ie postmeta content) - you should use update_post_meta

  • 1
    it's update_post_meta ;) Commented Jun 29, 2011 at 14:33
  • @thedeadmedic - doh! annoying inconsistent WP function naming conventions. Corrected - thanks.
    – anu
    Commented Jun 29, 2011 at 14:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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