Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • How to remove product tabs

    • 1
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 970
    Comment on it

    Hi,
    If you want to remove all tabs or any particular tab for example description and reviews, then use the below code in the functions.php:

    add_filter( 'woocommerce_product_tabs', 'FindNerd_remove_product_items', 58 );
    function findnerd_remove_product_items( $items ) {
        unset( $items['description'] );                      // To remove description item
        unset( $items['reviews'] );                           //To remove reviews item
        unset( $items['additional_information'] );      //To remove additional information item
        return $items;
    }
    

    In above code- woocommerce_product_tabs- is a predefined function, which refers to the action you are performing.
    FindNerd_remove_product_items' 58- FindNerd_remove_product_items- is a built-in function, this you can rename it according to your wish and 58 is a position where your function hits to perform function.

    Or if you want to remove the reviews tab so that only product description appears add this single line code to your custom.css file-

    .woocommerce .woocommerce-tabs ul.tabs {display:none !important}
    

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: