How do I save term?
-
How do I save term?
function functiondolarfull( $post_id ) { $terms10 = ''; $getslugid = wp_get_post_terms( $post_id, 'my_taxonomy' ); $slugs = implode(', ',wp_list_pluck($getslugid,'slug')); ?> <div class="dolarfull-label"> <label>Dolar Full</label> </div> <div class="dolarfull-fields"> <input type="text" name="testgo1" value="<?php echo $slugs; ?>"> </div> <?php } add_action( 'ACTIONHOOKDOLARFULL', 'functiondolarfull', 10, 3 );
the top is ok
the problem is on the bottom
function update_my_function( $post_id ) { if ( isset( $_POST['my_custom_field'] ) ) { wp_update_term(10000000000000000, 'my_taxonomy', array('name' => $_POST['my_custom_field'])); } }
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘How do I save term?’ is closed to new replies.