Title: Problem Using add_post_meta()
Last modified: August 30, 2016

---

# Problem Using add_post_meta()

 *  [felecl](https://wordpress.org/support/users/felecl/)
 * (@felecl)
 * [10 years, 6 months ago](https://wordpress.org/support/topic/problem-using-add_post_meta/)
 * I’m trying to add post metadata on a Custom Post Type, but didn’t display on 
   the Control Panel of my Custom Post Type. I’m using this frontend code with html
   form.
 *     ```
       $title = $_POST['titulo'];
       $content = $_POST['contenido'];
       $post_type = 'sgpa_proyecto';
       $curso = $_POST['proyecto_curso'];
   
       $new_post = array(
       'post_title' => $title,
       'post_content' => $content,
       'post_status'   => 'publish',
       'post_type'     => $post_type
       );
   
       $post_id = wp_insert_post($new_post);							add_post_meta($post_id, 'proy-curso', 'ELO-230',true);
       ```
   
 * Please Help!
 * [https://wordpress.org/plugins/types/](https://wordpress.org/plugins/types/)

The topic ‘Problem Using add_post_meta()’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/types_ced1d3.svg)
 * [Toolset Types - Custom Post Types, Custom Fields and Taxonomies](https://wordpress.org/plugins/types/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/types/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/types/)
 * [Active Topics](https://wordpress.org/support/plugin/types/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/types/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/types/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [felecl](https://wordpress.org/support/users/felecl/)
 * Last activity: [10 years, 6 months ago](https://wordpress.org/support/topic/problem-using-add_post_meta/)
 * Status: not resolved