• Resolved seowebby

    (@seowebby)


    Since I’d like a product category media organization, I selected the corresponding “not media taxonomy” and de-selected the “media category” option in media settings.
    This allows the possibility, in the library dashboard, to filter media by the product category.
    Ok! Is there any possibility to have, in the library dashboard, near the media and the author column, another column with the product category?

    Maybe it’s implemented in the pro version?

    Thank you

    Sergio

    https://www.ads-software.com/plugins/enhanced-media-library/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author webbistro

    (@webbistro)

    Hello Sergio,

    Sorry for the delay with the reply!

    WooCommerce product categories don’t have show_admin_column parameter set by default. Please add the following code to your theme functions.php file to make product columns work for your media library:

    add_action( 'wp_loaded', 'your_prefix_on_wp_loaded' );
    
    function your_prefix_on_wp_loaded() {
    
        global $wp_taxonomies;
    
        foreach ( get_taxonomies_for_attachments( 'object' ) as $taxonomy => $params ) {
    
            if ( in_array( 'attachment', $params->object_type ) && in_array( 'product', $params->object_type ) ) {
    
                // turns on taxonomy columns
                $wp_taxonomies[$taxonomy]->show_admin_column = 1;
            }
        }
    }

    Best,
    -Nadia

    Thread Starter seowebby

    (@seowebby)

    Great!

    I works perfectly. I added the code at the end of the file functions.php

    Do you know how to add it within a child theme?
    I know how to add a child style.css file but not the functions.php file.

    In this case, I only should integrate the main file.

    Thank you very much, I think I gonna buy the PRO version because of the Bulk Attachment. This means that I can attribute category to multiple photos at once, isn’t it?

    Plugin Author webbistro

    (@webbistro)

    Sergio,

    The child functions.php should be created just like the child style.css (see https://codex.www.ads-software.com/Child_Themes).

    The PRO version allows to attach images to categories in bulk, also it has improved bulk selecting and deleting, and you can create filter-based galleries with the WordPress native gallery edit popup, without editing the shortcode manually.

    Best,
    -Nadia

    Thread Starter seowebby

    (@seowebby)

    Very well!
    You earned your fee!!!

    Sergio

    Plugin Author webbistro

    (@webbistro)

    Haha, great! Thanks! Hope you will enjoy it.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Product category in the library dashboard’ is closed to new replies.