In WooCommerce, I'm using this code to put a text in the price display:
function cw_change_product_price_display( $price ) {
$price .= ' TEXT';
return $price;
}
add_filter( 'woocommerce_get_price_html', 'cw_change_product_price_display' );
add_filter( 'woocommerce_cart_item_price', 'cw_change_product_price_display' );
The page displays like "$99,99 TEXT"
I want to make it displays like this: "TEXT $99,99"
Thank you for the help.
use this code, if you haven't price for all of your products, then text before the price will not show up!
good luck ;))
use "woocommerce_currency_symbol" hook something like this :
hope it will help
You have just to inverted the price and the text:
This should work as you expect…