Support

Account

Home Forums Front-end Issues How to Display all fields in a group Reply To: How to Display all fields in a group

  • $fields = get_field_objects(); requires a post ID, if none is supplied then it returns values for the current post. Exactly what that values is depends on the page it’s running. So, the field in question for the current post in your case only has 2 values. These posts have information on how you can get fields in specific field groups.

    ACF5
    https://support.advancedcustomfields.com/forums/topic/get-all-fields-by-group-id/
    https://support.advancedcustomfields.com/forums/topic/how-to-get-all-acf-groups-or-field-for-specific-post-type/
    https://dream-encode.com/acf-get-all-fields-in-a-field-group/

    ACF4
    https://support.advancedcustomfields.com/forums/topic/get-fields-in-a-group-or-tab-for-output/