Remove 'Continue Shopping' button from checkout in Woocommerce

-1

Hello,doesanyoneknowhowtoremovetheinformationandthe'continueshopping'buttonfromthecheckoutinWoocommerce?Instead,Iwouldaddthedescriptionofthekitbeingpurchased.

Iwouldliketoleavetheimagebelow:

    
asked by anonymous 10.11.2015 / 19:16

1 answer

0

Looking for "Continue Shopping" in the plugin code, brings to file wc-cart-functions.php#L88 ", where you have this filter:

 
wc_add_notice( apply_filters( 'wc_add_to_cart_message', $message, $product_id ) );

The following code in your functions.php or custom plugin would remove the warning:

add_filter( 'wc_add_to_cart_message', '__return_empty_string' );
# pode tentar __return_null também

If there is any trace, it should probably be removed with CSS or editing the relevant file in the theme / child-theme used on the site.

And to get to the output you describe, you should filter by product_id and use something like:

add_filter( 'wc_add_to_cart_message', function( $msg, $id ){
    if( $id == SEU_PRODUCT_ID ) $msg = "Produto tal";
    return $msg;
}, 10, 2 );
    
16.11.2015 / 04:15