Support

Account

Home Forums Front-end Issues Trying to add conditional display to blog-list Reply To: Trying to add conditional display to blog-list

  • empty depends on what the value is.

    https://www.php.net/manual/en/language.types.boolean.php#language.types.boolean.casting.

    The values in the field object are the values before acf has formatted them (raw value), a true/false field set to false could be a string value "0" which is not empty.

    Try get_fields() instead of get_field_objects() and then use get_field_object() for non empty fields to get the field label.