Today we take a look at the WooCommerce Checkout page and specifically at how to add a Custom Extra Fee for Non-Continental US States. You can do the exact same thing for a non-US State, as long as customers will feel comfortable in paying extra! Continue reading WooCommerce: Add Shipping Fee for Non-Continental States
Today we take a look at the WooCommerce Minimum Order Amount. This snippet displays an error notification on the Cart Page and an error message @ Checkout Process if the order is below a set threshold. Continue reading WooCommerce: Define a Minimum Order Amount
Hello WooCommerce Customizers!
Episode #8 of my “18 snippets in 18 days” challenge (we have 10 days and 10 snippets to go) features a nice HTML hack.
Who doesn’t love hacks? 🙂
I remind you to share on social media and leave blog comments to support my marathon 🙂
Today we take a look at the WooCommerce Loop and specifically at how to disable the link to the products. Some store owner does not want to get people to the single product page, and simply have customers to add to cart! Continue reading WooCommerce: Disable Link to Product @ Loop
Today we take a look at the WooCommerce Checkout and specifically at how to disable a payment gateway (e.g. PayPal) if certain product categories are in the cart.Continue reading WooCommerce: Disable Payment Method for Specific Category
Today we take a look at the WooCommerce Checkout Page and specifically at how to disable a payment gateway (for example PayPal) when a specific shipping method is selected (e.g. “local_pickup”). Enjoy!Continue reading WooCommerce: Disable Payment Gateway For Specific Shipping Method
In this blog I’ve put together a series of WooCommerce links, tutorials, videos, blogs and resources so that you can find what you’re looking for. Enjoy! Continue reading WooCommerce Resource Library
Hey Woo Developers. I’ve created a visual HTML hook guide for the WooCommerce Checkout Page.
This visual guide belongs to my “Visual Hook Guide Series“, that I’ve put together so that you can find WooCommerce hooks quickly and easily by seeing their actual locations – and you can also easily copy & paste. Enjoy!
I’ve created a visual HTML hook guide for the WooCommerce Archive Page (which is the same page for the Shop, Category, Tag pages). This visual guide belongs to my “Visual Hook Guide Series“, that I’ve put together so that you can find WooCommerce hooks quickly and easily by seeing their actual locations (and you can also copy/paste). If you like this guide and it is helpful to you, let me know in the comments!
Thanks to this WooCommerce Archive Visual Hooks Guide, you can now go to your template’s functions.php file and use “add_action(‘place-hook-here’,’your-PHP-function-here’);” – you can then place your custom functions exactly where you like them to be. Enjoy!
Here’s a visual HTML hook guide for the WooCommerce Single Product Page. This is part of my “Visual Hook Guide Series“, through which you can find WooCommerce hooks quickly and easily by seeing their actual locations (and you can copy/paste). If you like this guide and it’s helpful to you, let me know in the comments!
Now that you know the Single Product Page hooks, all you need to do in your functions.php is “add_action(‘place-hook-here’,’your-PHP-function-here’);” and you can place your custom functions exactly where you like them to show! Need a video tutorial? Watch it now → Continue reading WooCommerce Visual Hook Guide: Single Product Page
Here’s a simple PHP snippet to add a fee to the checkout for every payment or for a specific payment gateway.
Please do remember that for certain payment gateways such as PayPal, adding checkout fees is currently against their Terms of Service so make sure to check this first.
As usual, this needs to be copied and pasted in your child theme’s functions.php file. Enjoy!Continue reading WooCommerce: Add Checkout Fee for a Payment Gateway (e.g. PayPal)
This is a workaround to Limit Shipping and Billing to One State Only. In two of my previous posts (Limit Shipping to One State Only and Limit Billing to One State Only) we’ve seen similar functionalities. In this case, let’s imagine we want to avoid that the user selects unwanted states. Continue reading WooCommerce: Limit State Dropdowns to One State Only
A client had several shipping rated on the cart page, automatically generated from FedEx, USPS, UPS and similar plugins via their API. Problem was, he wanted to sort them by price as opposed to grouping them by provider. Continue reading WooCommerce: Sort Shipping Costs from Low to High
This simple snippet will make sure you can send users back to a custom page as opposed to the shop page when the Cart is empty. In this particular project, client had no shop page so we wanted to send users back to the homepage instead.
As usual, it’s a couple of lines of PHP, without the need to override templates or even worse to edit core WooCommerce. Enjoy!Continue reading WooCommerce: Change “Return to Shop” URL
I am a big fan of Elegant Themes, but a lot of CSS styles (mainly in Divi) contain “!important” in order to override WooCommerce styles when using the two in a combo. Now, the big problem is that we can’t override !important with another !important. Divi will win. But no matter whether Divi has been developed in a good or not so good way, there is something we can do. (NOTE: using !important is a horrible thing in CSS. Use at your own risk) Continue reading WooCommerce and Divi: how to override !important CSS
On a website using USD and WooCommerce Subscriptions, a weird error showed up. After doing a bit of research, I found out that orders above $999.99 were showing as $1 on the Cart and Checkout page. Pretty weird! Here’s how I fixed it. Continue reading WooCommerce: Fix for Wrong Order Total
Interesting WooCommerce customization here. A client of mine asked me to hide/remove prices from the shop page and category pages as she wanted to drive more customers to the single product pages (i.e. increasing the click-through rate).
As usual, a simple PHP snippet does the trick. I never recommend to use CSS to “hide” prices, as they would still be visible in the code – PHP stops the prices from loading, so they’re invisible to the user. Continue reading WooCommerce: Hide Prices on the Shop & Category Pages
This is a cool function you can apply to any payment gateways for any order threshold. for example, you may want to disable bank transfers if orders are below $10, or disable PayPal payments if orders are above a certain cart total. Here’s what I did. Continue reading WooCommerce: How to Disable PayPal on Orders Above $100
WooCommerce database already stores the number of products sold for you.
Therefore, you may want to show such number on the product page, close to the Add To Cart button. As we’ve seen in my book Ecommerce and Beyond, showing the number of sales for each product can increase your sales conversion rate.
All you need is pasting the following code in your functions.php. Enjoy!Continue reading WooCommerce: Show Number Of Products Sold @ Product Page
You may want to disable payment gateways depending on the user role or user capability. For example, you may want to disable PayPal for “user role: shop_manager” or enable a specific gateway for “user role: customer”. All you need is pasting the following code in your functions.php Continue reading WooCommerce: Disable Payment Gateway for Specific User Role
If Free Shipping is available, you possibly don’t want to show the other paid shipping options. WooCommerce shows by default all shipping rates that match a given shipping zone, so it’s not possible to achieve this from the settings alone.
You need PHP for that. In this example, we will disable all shipping methods but “Free Shipping” so that free shipping remains the only possible choice. And here’s the code to add to your functions.php 🙂Continue reading WooCommerce: Hide Shipping Rates if Free Shipping Available