Home Forums General Issues How to use update_field($field_taxonomy, $term_taxonomy, $post_id)? Reply To: How to use update_field($field_taxonomy, $term_taxonomy, $post_id)?

  • It depends on the type of field your showing for a taxonomy field. If you are using a checkbox or multiselect then it stores and array of term IDs, if you have it set for radio of single select then it stores a single term ID.

    Here’s the way to tell what will be stored for most fields.

    If the field allows only a single value then it will be a single value.

    If the field allows multiple values then ACF will store and array.

    If the field is some type of relationship or you are choosing another object then ACF stores the ID of that object. This includes posts, pages, attachments (media), and terms.

    As an example, a gallery field allows you to select multiple images. ACF stores and array of attachment IDs.

    There are some fields that do not follow this logic, and I don’t recall exactly what they store. These are things like the Page Link, omebed and google map fields. I don’t use them much so I’ve never had a reason to look into them.

    Hope this help you.