From the course: WordPress: Customizing WooCommerce Themes

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Add an Empty Cart button

Add an Empty Cart button - WordPress Tutorial

From the course: WordPress: Customizing WooCommerce Themes

Start my 1-month free trial

Add an Empty Cart button

- [Instructor] Many industries are fairly straightforward and users can find what they want, add it to the cart, and check out. But some industries aren't that straightforward. If you're selling clothes for example, your users may hem and haw about what shirts go with what pants, and they may add all of these items to their cart to see them next to one another, and then decide to try something else, and empty the cart. If you're building a site for industry like this, you may want to consider adding an empty cart button to make the process a bit easier for your user, and they should be more likely to go all the way through the checkout. The first thing we have to do is add a button to the cart page. If you open up the WooCommerce plug-in, and then go to templates, cart, and cart.php, you'll see the entire cart page. If you scroll down a little bit, you'll see the update cart button. That's right here. And if you look down here, there's an action that we can hook in to. I'm gonna copy…

Contents