WooCommerce – Some Pending New Plugins

I have a number of small customisations for WooCommerce that I have done for a couple of clients. These are customisations that could possibly be of use to others, and can be installed as a plugin. Depending on demand, I may release them, but it really does depend on demand. Here is a summary. If you want any of these, please let me know.

Duplicate Imported Image Removal

The CSV Import Suite will import products and variations. One problem with importing variations is an issue of duplicated images.

If you have more than one variation on a product that has the same image, then the import suite will create a fresh copy of each image for each variation. For some shops that have many variations, this can slow things down a lot, as there are more images to handle, more traffic for downloading, more copies of images that need to be pulled into browsers instead of downloading once and caching.

My plugin will scan all the images on the system and give each a unique signature. The signature is based on the content of the image and not its name, so two identical images will have the same signature even if one is called Foo.jpg and the other Bar.jpg (or more likely, “MyProductX.jpg” and “MyProductX_1.jpg”, “MyProductX_2.jpg” etc.

It will then take all the duplicates and and detach all but the main one (the earliest uploaded) from every variation that uses any of the duplicates. What you end up with, is a bunch of unattached duplicate images in the media library that can be safely deleted.

Exclude Variant Prices

When a product has a number of variations of varying prices, WooCommerce will take the lowest price and use that to label the product. The price will show as “From £x” or “From $x”.

Sometimes, one or more of the variations are just samples, and so have a much lower price than the full product. You may not want to include those variations in the calculation of the “from” price.

My plugin will add a checkbox to each variation so you can indicate that it should not be used in the price calculation. So if you have, for example, a big pot of yellow paint for £40 and a big pot of magenta paint £35, and a sample of each for 99p, then WooCommerce would normally list that product as being “From 99p”. By ticking the two samples to be excluded, the product will display as costing “From £35”.

Lost Data with Many Variations

If your product has many variations (around 40+ in my experience)  then some of the variation data submitted to the server when saving a product can get lost en-route. This is due to a security feature of PHP, but it all happens without warning.

My plugin, which is already released, can be left installed in the background to protect you. It will warning you if you are about to save or update a product that will get corrupted due to this problem. This gives you a chance to make some changes to settings on the server before you really update the product.

You can download it from here or install the latest “WP Max Submit Protect” plugin from within your WordPress installation.

Hiding Prices for Non-Privileged Users

This plugin allows prices to be hidden from users depending on their role. The Capabilities Manager plugin is used to specify which roles are allowed to see the prices, and everyone else gets to see a  message of your choice instead.

This is useful if you need to check out a customer before allowing the prices to be seen. A strange idea? Think wholesale – business to business trade. You may be happy for the world to see your range of products, but only want the wholesale prices to be visible to approved users or businesses.

2 Responses to WooCommerce – Some Pending New Plugins

  1. Wesley 2014-06-03 at 16:16 #

    Hi Jason
    have you even come across a problem where a CSV import of variations can corrupt a file that stops the product being view on it’s own page.

    Im currently having this problem where in the moment that i Put variations in the product. it becomes unviewable on it’s own page. without variations the product dislays perfectly.

    please let me know if you have come across this problem.

    Kind regards

    • Jason Judge 2014-06-25 at 15:13 #

      Hi Wesley,

      Sorry for the delay – not been getting notifications from my blog.

      I’ve not come across this problem. Usually what goes wrong is the variation attributes not being set correctly, so no variations from be selected in the shop. But even then, the product can still be loaded. You may be able to see if there are any clues in the variations that have been loaded. You can see these by going to the admin products list, then changing “products” in the URL to “product_variations”. That will then list the variations that you can edit (but not view) individually.

      — Jason

Leave a Reply