GazChap’s WooCommerce Auto Category Product Thumbnails

0

By default, WooCommerce will only show thumbnails for categories if the category has a thumbnail set. This plugin changes this behaviour so that WooCommerce will hunt for a product thum

Version
Last updated
Active installations
WordPress Version
Tested up to
PHP Version
Rating
Total ratings
Tag

Description

By default, WooCommerce will only show thumbnails for categories if the category has a thumbnail set.

This plugin changes this behaviour so that WooCommerce will hunt for a product thumbnail in the category being displayed, and use that instead.

Upon activation, the plugin will configure itself with the basic settings. Any categories that you have on your WooCommerce store that do not have a thumbnail set will then start displaying any available product thumbnails inside the category.

There are a number of options, these can be found in WooCommerce -> Settings -> Products -> Auto Category Thumbnails.

  • Thumbnail Size sets the image size that the plugin should use when displaying the thumbnails. Defaults to shop_thumbail, but shop_catalog may be a better option for some themes.

  • Go into Child Categories makes the plugin look in child categories too, useful if you have products buried in quite a deep category structure.

  • Random Thumbnail tells the plugin to pick a random product thumbnail from those it finds every time the page loads – otherwise it always uses the first one it finds.

  • Use Transients tells the plugin to save the thumbnail it picks for a category as a transient in WordPress, so that it won’t have to do it again while the transient is still active. This can hugely increase performance on sites with many categories, so is enabled by default.

  • Transient Expiry is the length of time each transient is active for before the site picks another thumbnail for the category. By default it is set to 1 day.

  • Custom Transient Expiry can be used to define your own transient expiry period (in seconds) if none of the pre-defined options are suitable.

  • Exclude Thumbnail IDs accepts a comma-separated list of attachment IDs from the WordPress Media Library. The plugin will never use any thumbnail with one of these IDs for a category.

License

Licensed under the GNU General Public License v2.0