• Resolved MaxCode

    (@mswebworld)


    After update of Metabox version 5.4.5, option tree is not working.

    I am using below example code for my theme.

    Option:

    array(
    	'name' => 'Categories',
    	'id' => "exclude_pf_cats",
    	'type' => 'taxonomy',
    	'options' => array(
    		'taxonomy' => 'portfolio-categories',
    		'type' => 'checkbox_tree',
    		'args' => array()
    	)
    ),

    call function:

    $get_cats = rwmb_meta( 'exclude_pf_cats', 'type=taxonomy&taxonomy=portfolio-categories' );

    • This topic was modified 4 years, 11 months ago by MaxCode.
    • This topic was modified 4 years, 11 months ago by MaxCode.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Peter

    (@longnguyen89)

    Hi,

    It might be the old type to register the taxonomy field. Please follow this documentation to know how to register a taxonomy field with new settings type https://docs.metabox.io/fields/taxonomy/

    array(
        'name'       => 'Categories',
        'id'         => 'exclude_pf_cats',
        'type'       => 'taxonomy',
    
        // Taxonomy slug.
        'taxonomy'   => 'portfolio-categories',
    
        // How to show taxonomy.
        'field_type' => 'checkbox_tree',
    ),
    

    and use the filter hook rwmb_meta_boxes https://docs.metabox.io/creating-meta-boxes/#using-code

    Thread Starter MaxCode

    (@mswebworld)

    Thank you Neo for your fast support.

    I tried as per your suggestion and it worked.

    Problem is solved 🙂

    Great plugin, great author and great support team 🙂

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Checkbox tree is not working’ is closed to new replies.