Support

Account

Home Forums General Issues Dynamically Generated ACF Tab Names Reply To: Dynamically Generated ACF Tab Names

  • You’re looking to alter the label of a tab field

    
    function my_acf_prepare_field( $field ) {
      global $post;
      if (get_field('some other field', $post->ID) {
        $field['label'] = get_field('some other field', $post->ID);
      }
      return $field;
    }
    
    add_filter('acf/prepare_field/type=tab', 'my_acf_prepare_field');