How to change the word “Sale” on the WooCommerce sale badge

May 25, 2019 | WooCommerce Tips | 0 comments

Add the function below to your child theme functions.php file.

// change Sale to Save on the sale badge
add_filter( 'woocommerce_sale_flash', 'wc_custom_replace_sale_text' );
function wc_custom_replace_sale_text( $html ) {
    return str_replace( __( 'Sale!', 'woocommerce' ), __( 'Save!', 'woocommerce' ), $html );
}

0 Comments

Submit a Comment

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.