WooCommerce how do you change Cart to Basket?

WooCommerce is great but there doesn’t seem to be a built in easy way to change the American term ‘Shopping Cart’ to ‘Shopping Basket’. If you are running a British or European based business changing this phrase is essential if you want your store to look professional.

I have developed a simple solution. All you need to do is paste the following function into your themes functions.php.

		   function ($translated_text, $text, $domain) {

			if ($domain == 'woocommerce') {
				switch ($translated_text) {
					case 'Cart totals':
						$translated_text = __('Order summary', 'woocommerce');
					case 'Update cart':
						$translated_text = __('Update basket', 'woocommerce');
					case 'Add to cart':
						$translated_text = __('Add to basket', 'woocommerce');
					case 'View cart':
						$translated_text = __('View basket', 'woocommerce');

			return $translated_text;

20, 3);

This code processes all the output from your WordPress WooCommerce store and dynamically replaces Cart with Basket.

If you have any questions, or if you spot somewhere in Woocommerce that I’ve missed do please leave a comment below.

Recommended essential WordPress Plugins

I’ll be updating this blog post from time to time with my list of essential WordPress Plugin’s. These are the plugins that I find myself using time and time again on different sites because they are reliable.

Divi Builder from Elegant Themes

See https://www.elegantthemes.com

This is a great page builder for easily creating professional websites. There are alternatives but I’ve found that the Divi Page builder has a good support eco-system online and Elegant Themes are constantly developing and adding new features.

Child Theme Configurator By Lilaea Media

See https://wordpress.org/plugins/child-theme-configurator/

When working with third party themes it’s essential that you don’t directly change the vendors theme files because any changes you make will be wiped out when you receive updates.

The correct method of making local customisations is to create a child theme. You can do this manually but I find it really helpful to use this great little plugin.

How to insert a table / row into a WordPress page.

How to insert a table / row into a WordPress page.

Wordpress missing insert table row editor function


These days we try to avoid using HTML tables for layout purposes but there are times when a table is absolutely the right answer, for example when laying out a set of data points, pricing information or other structured data.  Yesterday I was helping my son with a blog post using WordPress and told him to insert a table only to find that by default these days the WordPress editor doesn’t actually have an Insert > Table or Insert > Table > Row function. We were in a hurry at the time and we needed to get the job done so I just popped into the HTML view and entered the code. I’m happy to do this as I’ve been writing HTML and the like since the dawn of time… but it’s not acceptable or a great experience for people starting out or those who just don’t want to get into that detail.

Wordpress editor without insert table

This picture shows the default WordPress editor without an Insert Table button

Today I’ve had a bit more time to research this and I’ve found that the WordPress Insert Table and WordPress Insert Table Row editor functions can easily be added back via a very popular plugin.

Wordpress Table Editor Plugin

This graphic shows how to locate the WordPress Table Editor plugin.


To add the WordPress Table editor function, click on Plugin’s on the left hand navigation menu. Then in the keyword search box in the top right enter “MCE Table Buttons”.  You should then see a plugin called “MCE Table Buttons” (shown here top right). As you can see it’s very popular with over 100,000 active installations.  Just click the Install Now button and then activate the plugin.

Wordpress Editor with Insert Table function enabled.

This graphic shows the WordPress editor after we have enabled the Table Editor functions that allow you to add tables, columns and rows to your HTML tables in WordPress.

Once you have installed the MCE Table Buttons plugin you will then find the missing Table Editor button in the WordPress Editor.

If you have any questions about HTML tables or using the Table Function in the WordPress Editor just leave a question in a comment below and I’ll try and get straight back to you.

Image Resize and thumbnails not working in WordPress.

I had a strange problem on a WordPress blog site today that I haven’t seen before.  The image resize and thumbnail generation wasn’t working.  Normally when you upload an image to WordPress it creates 3 versions of the image at different sizes but this wasn’t happening and I was just left with the large original file.

When I went to insert the image into a post the resize options were disabled (or greyed out).

Wordpress resize disabled

WordPress resize disabled

At first I thought it might have been caused by a problem with the Theme I was using but the problem continued after switching back to one of the standard themes.  Then I checked the directory permissions incase the WordPress install didn’t have authority to write the resized images back to the file system, but again that was all fine.

It turns out that WordPress uses the Apache PHP5-GD library to do it’s resizing and for some reason on the build of Ubuntu Linux on the server I was using this wasn’t installed by default.  To check this I just put a phpinfo(); into a small dummy php file and ran it from the browser.   What you should see is something like this:

Is Apache gd installed?


If you don’t see this then it’s simple to install with

sudo apt-get install php5-gd

and then restart Apache and you’re done.

WordPress 3.0

Just upgraded to WordPress 3.0. The upgrade process was straight forwards and painless. First impressions are very good. I’m also trying the latest version of the WordPress iPod app. With a little luck it will make it easier to blog a little more often.