2

I would like to replace the text "Price" to "Value" in the description row of the shopping cart table of woocommerce.

How can I do this?

1 Answer 1

1

Try the following:

add_filter('gettext', 'change_price_text_in_cart_page', 105, 3 );
function change_price_text_in_cart_page( $translated, $text, $domain ) {
    if( is_cart() && $text == 'Price' ) {
        $translated = __('Value', $domain );
    }
    return $translated;
}

Code goes in function.php file of your active child theme (or active theme). Tested and works.

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.