• Hello to the community!

    I’ve hidden the SKU on the product pages using the following code, but it doesn’t hide the same SKU in the modal product preview window. Does anyone know how to do this please?

    (I know that if I don’t fill in this information in the product, it doesn’t appear on the preview, but how to use this field without displaying it, that’s my question)

    Here is the code used to hide the SKU code on the product pages :

    // Hide SKU on products / Cacher l’UGS sur les produits
    add_filter( ‘wc_product_sku_enabled’, ‘bbloomer_remove_product_page_sku’ );

    function bbloomer_remove_product_page_sku( $enabled ) {
    if ( ! is_admin() && is_product() ) {
    return false;
    }
    return $enabled;
    }

Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘hide SKU on product preview’ is closed to new replies.