Title: custom fields in post(create,update)
Last modified: August 24, 2016

---

# custom fields in post(create,update)

 *  [褚 找钱](https://wordpress.org/support/users/heisehuanyun/)
 * (@heisehuanyun)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/custom-fields-in-postcreateupdate/)
 * from:
    **<input name=”custom_fields[lwygoods]” value=”” type=”text”>**
 * json-api\models\post.php -> function save
 * if (!empty($values[‘custom_fields’])) {
    $custom_fields = $values[‘custom_fields’];
   foreach ($custom_fields as $key => $value) { //echo $this->id,'</br>’; //echo
   $key,'</br>’; //echo $value,'</br>’; update_post_meta($this->id, $key, $value);}}
   but create post success donot show custom_fields . In fact, it has been to create
   success.
 * [https://wordpress.org/plugins/json-api/](https://wordpress.org/plugins/json-api/)

Viewing 1 replies (of 1 total)

 *  Thread Starter [褚 找钱](https://wordpress.org/support/users/heisehuanyun/)
 * (@heisehuanyun)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/custom-fields-in-postcreateupdate/#post-6037387)
 * if thumbnail
 * <input value=”435″ name=”custom_fields[_thumbnail_id]” class=”wpfepp-thumbnail-
   id wpfepp-form-field” type=”text”>
 * 435 thumbnail’s ID

Viewing 1 replies (of 1 total)

The topic ‘custom fields in post(create,update)’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/json-api.svg)
 * [JSON API](https://wordpress.org/plugins/json-api/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/json-api/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/json-api/)
 * [Active Topics](https://wordpress.org/support/plugin/json-api/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/json-api/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/json-api/reviews/)

 * 1 reply
 * 1 participant
 * Last reply from: [褚 找钱](https://wordpress.org/support/users/heisehuanyun/)
 * Last activity: [11 years, 1 month ago](https://wordpress.org/support/topic/custom-fields-in-postcreateupdate/#post-6037387)
 * Status: not resolved