How to change the word “Sale” on the WooCommerce sale badge
Add the function below to your child theme functions.php file.
[php]
// 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 );
}
[/php]
Need help with this?
Hire me for a consultation and I'll walk you thru the process.
0 Comments