Hello,
I have a front-end form which I am using to allow users to create comments and posts. I got managed to allow front end users to select from a list of taxonomies to append to a post via wp_set_object_terms() but I am wondering how I can also update_field() so that it displays properly in my backend.
Long story short, I am wondering for “taxonomy” type custom fields, what is the format for a list of terms that it takes to properly file it in the database? Can it take a whole list/array in one update_field() operation?
Right now, this doesn’t work:
$terms = array( 6, 8 );
wp_set_object_terms($post_id, $terms, 'custom-taxonomy-name'); // This works
update_field('field_xxxxxxx', $terms, $post_id); // This does NOT work