A plugin that aligns WooCommerce "Add to cart" buttons.
This lightweight plugin will automatically align your WooCommerce “Add to cart” buttons.
Nothing looks worse than visiting a WooCommerce shop page to find the “Add to cart” buttons scattered all over the place like a dog’s breakfast.
This simple plugin solves that problem with a little javascript, and without modifying any core files or templates.
This version will also align your Product Titles thus allowing longer titles or larger fonts.
See FAQ about issue with WooCommerce blocks.
woo-align-buttons.zip
through the “Plugins” menu in WordPresswoo-align-buttons
folder to the /wp-content/plugins/
directoryIt hooks a wrapper <div>
around the product information above the “Add to cart” buttons.
Javascript then measures the height of that wrapper and adjusts the height to automatically align the buttons.
No. It is designed to work on unmodified WooCommerce files. If your theme has modified any WooCommerce product templates or added hooks that affect those templates or files, this plugin may not work.
It is assumed that if the theme developer has hacked, hooked, or modified any WooCommerce files, they should have already fixed the problem with aligning the buttons.
If it is not working on your theme chances are your theme has been modified or hacked, and this plugin will NOT work.
You can either choose another theme, or contact your theme developer and ask them to fix their theme.
Yes. However, the hook in your theme’s functions.php
file will need to be modified slightly.
A sample child theme can be found here on GitHub.
No. WooCommerce has changed the products grid template for their blocks.
Their new template does not allow for separating the ‘Add to cart’ buttons.
Without the ability to separate the buttons, this plugin can not work.
This issue would need to be taken up with WooCommerce Support.
There appears to be a handful of users experiencing issues with the latest updates.
This is most likely caused by previous version files being cached on the users system.
You can try clearing your cache files.
Yes. Every time the screen is resized, it will re-adjust the buttons.
Don’t know. Try it for yourself. It’s Free.
If your theme has been heavily modified and the buttons are outside of the original scope, you may have to consider using another theme.
If you are able to do some of your own coding, a child theme can usually be made to work.
A sample child theme can be found here on GitHub.
woo-align-public.js
file