Changing the “description” text in WooCommerce to something else

A recent client had, what I thought, was a simple request in WooCommerce. Instead of the Header text for a product saying ‘Description’, he wanted it to say ‘Information’ instead. This should be simple but it does require a little jiggery-pokery to get it to work…The easiest way I found of achieving this is to add a translate filter to the function.php file. What this will do is replace the word you want to change with the one you want.

Please, BACK UP your site before doing this. UpdraftPlus is one of the better plugins!

Log into the dashboard of your WooCommerce website and from the left menu choose: Appearance –> Editor

What you’re looking for is the Theme Functions file called functions.php

Go to the very bottom of the page and add this code:

add_filter(‘gettext’, ‘translate_text’);
add_filter(‘ngettext’, ‘translate_text’);

function translate_text($translated) {
$translated = str_ireplace(‘Description’, ‘Information’, $translated);
return $translated;
}

In the above example, I am changing the word ‘Description‘ to ‘Information

Save the file and you should be good to go!

Simon Day

If you have a wedding, portrait, event or festival coming up please contact me. Likewise for portraits. Check out my social media channels: Instagram | Facebook | Twitter