Form to custom post type and custom taxonomy
Use WP set object terms $new_post = array( ‘post_title’ => $title, ‘post_content’ => $description, ‘tags_input’ => array($tags), ‘post_address’ => array($address), ‘post_status’ => ‘draft’, // Choose: publish, preview, future, draft, etc. ‘post_type’ => ‘trademen’ //’post’,page’ or use a custom post type if you want to ); //save the new post $pid = wp_insert_post($new_post); wp_set_object_terms( $pid, $industry, … Read more