WooCommerce Mini Cart Divi Menu Header Not Updating

If your Divi theme is not updating the menu header WooCommerce cart count when you add an item via AJAX there’s a fix.  Use the following WooCommerce snippet to ensure the cart contents count is updated in the Divi navigation menu having to refresh the page.  

The trick here to ensure the cart […]

Read More…

Change Background Color Photoswipe WooCommerce 3

To change the background of WooCommerce 3 new photoswipe lightbox which appears in the single-product.php template, use the following CSS in your theme to invert the colors to white.

[…]

Read More…

Disable WooCommerce Payment Gateways Based On Cart Amount

Disable WooCommerce payment gateways is fairly straight forward once you know what the name of the gateway is. The following code will disable paypal and stripe payment gateways on the WooCommerce checkout page when the cart amount is greater than $1000. You can adjust the code to disable payment gateways based on certain products that […]

Read More…

Remove WooThemes IgniteWoo Updater Plugin Notice WordPress

remove wootheme ignitewoo plugin updater

To remove WooThemes and IgniteWoo update plugin notices, add the following code to your theme’s functions.php file.

[…]

Read More…

WordPress PHP Check Plugin Active

This was taken from the WordPress Codex reference for is_plugin_active In the Admin Area:

In the front end of a theme you need to include a reference to the following library

In this case $plugin is the directory of the plugin followed by the main php file. In this example below the event […]

Read More…

WooCommerce BCC Completed Orders Email

Adding an audit trail to WooCommerce completed orders emails is a fairly easy task. We can achieve this by employing the filter woocommerce_email_headers and adding in a check for the object name customer_completed_order. ** This will work for WooCommerce version less than or equal to 2.2 **

** For WooCommerce version 2.3 and above […]

Read More…

WooCommerce Duplicate Billing to Shipping Address For Virtual Products

With WooCommerce if a customer orders a virtual product there is no shipping address displayed on the checkout page.  This makes sense as there is no physical item being posted to your customer.  However, a few of my clients like to have the WooCommerce billing address match the shipping address.  Subsequently, I wrote this piece […]

Read More…

Add Custom Fields WordPress User Registration Page

To add custom fields WordPress user registration page we need to utilize the hook user_new_form because since WordPress 3.7 the hook register_form no longer works.  Here is an example of adding a checkbox to the end of the user registration form.

  Here is the result of us adding custom fields to WordPress user […]

Read More…