Hide weight and dimension information on single product

This topic has 4 replies, 3 voices, and was last updated 1 months ago ago by Luca Rossi

  • Avatar: LVRB Love's Rebel
    LVRB Love's Rebel
    Participant
    April 13, 2024 at 23:07

    Hello.

    I need to hide the weight and dimension information in the additional information section of single product, since it is not relevant information for my client, only for internal shipping use.

    Thanks!

    Please, contact administrator
    for this information.
    Files is visible for topic creator and
    support staff only.
    3 Answers
    Avatar: Rose Tyler
    Rose Tyler
    Support staff
    April 14, 2024 at 08:23

    Hello, LVRB Love’s Rebel,

    Thank you for reaching out to us with your request.

    We kindly ask that you refer to the following article for guidance on editing product data tabs: https://woocommerce.com/document/editing-product-data-tabs/

    Please note that the Additional Information tab is a feature provided by WooCommerce and is not specific to our theme. For further assistance with this matter, we recommend reaching out directly to WooCommerce Support – https://wordpress.org/support/plugin/woocommerce/

    Best Regards,
    8Theme’s Team

    Avatar: LVRB Love's Rebel
    LVRB Love's Rebel
    Participant
    April 14, 2024 at 16:11

    Hello.
    Thanks for the previous answer, but I tried the codes and it didn’t work for me.

    Could you help me by indicating the exact code to use to hide the weight and dimension attributes on my site so that they are not visible to the client?

    Please, I need that help.

    Please contact administrator
    for this information.
    Avatar: Justin
    Luca Rossi
    Support staff
    April 15, 2024 at 05:22

    Hi @LVRB Love’s Rebel,

    Please try adding the following code under functions.php file locates in your child theme:

    
    /**
     * @snippet       Hide Weight, Dimensions @ WooCommerce Single Product
     * @compatible    WooCommerce 8
     */
     
    add_filter( 'wc_product_enable_dimensions_display', '__return_false' );
    

    Hope it helps!

  • Viewing 4 results - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.Log in/Sign up

Helpful Topics

We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.