Custom Fields
Support MB Custom Taxonomy Custom taxonomy not shown by MEta Box

  • Creator
  • #22363
    Resolved Openstream Internet Solutions

    I have created a custom taxonomy which I want to provided as a select option in a custom post type.
    The taxonomy ist registered this way:

        $args = array(
          'labels'                     => $labels,
          'hierarchical'               => false,
          'public'                     => true,
          'show_ui'                    => true,
          'show_admin_column'          => false,
          'show_in_nav_menus'          => true,
          'show_tagcloud'              => false,
          'show_in_rest'               => true
        register_taxonomy( 'event_format', array( 'event' ), $args );

    I added the meta boy using this code:

              'type'       => 'taxonomy_advanced',
              'id'         => $prefix . 'format',
              'name'       => esc_html__( 'Format', 'events' ),
              'taxonomy'   => 'event_format',
              'field_type' => 'radio_list'

    Same code with taxonomy category is working:

              'type'       => 'taxonomy_advanced',
              'id'         => $prefix . 'format2',
              'name'       => esc_html__( 'Format', 'events' ),
              'taxonomy'   => 'category',
              'field_type' => 'radio_list'

    So, I assume there could be something wrong with the registration of the custom taxonomy. Maybe a flag is missing. What do I have to do to get the custom taxonomy visible in my taxonomy selector?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Author
  • #22365
    Long Nguyen


    Please share full the code that you use to create the custom post type, custom taxonomy and fields, I will check it on my end. You can also use some online tools Online Generator, Post Type Generator, Taxonomy Generator to generate the standard code.


    Hi Long Nguyen. Full code is not necessary. As I wrote, the only problem is the taxonomy list of a custom taxonomy. The rest is working as expected. As I wrote, the feature is working with the category, but not with my custom taxonomy. So, please provide a working the code where you register a taxonomy which is listed in the taxonomy_advanced type. Thanks!

    Long Nguyen


    I've made a short screen record using online tools to create a custom CPT, a custom taxonomy, and a custom field taxonomy_advanced

    Everything works as well.


    Thank you, Long Nguyen. I got it up and running with my original code. I don't know why it wouldn't work before.
    Thanks for your effort.

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.