• After the activation the custom taxonomies that i’ve added to woocommerce are hidden.
    Let me explain, in the backend the list of items of taxonomy is empty.
    If deactivate this plugin the taxonomies are showed.

    Code that i use for create a new taxonomy:

    add_action( 'init', 'custom_taxonomy_brands' , 9999);
    function custom_taxonomy_brands()  {
    $labels = array(
        'name'                       => 'Brand',
        'singular_name'              => 'Brand',
        'menu_name'                  => 'Brands',
        'all_items'                  => 'All Brands',
        'parent_item'                => 'Parent Brand',
        'parent_item_colon'          => 'Parent Brand:',
        'new_item_name'              => 'New Brand Name',
        'add_new_item'               => 'Add New Brand',
        'edit_item'                  => 'Edit Brand',
        'update_item'                => 'Update Brand',
        'separate_items_with_commas' => 'Separate Brands with commas',
        'search_items'               => 'Search Brands',
        'add_or_remove_items'        => 'Add or remove Brands',
        'choose_from_most_used'      => 'Choose from the most used Brands',
    );
    $args = array(
        'labels'                     => $labels,
        'hierarchical'               => false,
        'public'                     => true,
        'show_ui'                    => true,
        'show_admin_column'          => true,
        'show_in_nav_menus'          => true,
        'show_tagcloud'              => true,
        'publicly_queryable' => true,
        'query_var' => true,
        'rewrite' => array(
                'slug'          => 'brands',
                'with_front'    => true
      )
    );
    register_taxonomy( 'brands', 'product', $args );
    register_taxonomy_for_object_type( 'brands', 'product' );
    }

    https://www.ads-software.com/plugins/woocommerce-multilingual/

Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘On activation custom tax on woocommerce are empty’ is closed to new replies.