in Easy Digital Downloads, Tutorials, WordPress

Customising the Easy Digital Downloads Checkout Page

In Easy Digital Downloads, by default the Checkout page uses the page.php page template to generate the page. However, there are a few things you can do to customize the page.

Firstly, you can customize the layout of the checkout shopping cart by creating a template for it. In your theme create a folder called edd_templates and in there create a file called checkout_cart.php. Copy into that file the code from here.

It might look a little daunting at first but play around with this file as it enables you to completely customize the shopping cart’s layout and design just like you would any other theme template file.

Another part of the checkout page that you may want to customize is the sidebar. As previously mentioned, the checkout page is using the page.php template file to generate the layout, which is probably pulling in the standard sidebar that displays a whole lot of irrelevant information that customers about to checkout just don’t want or need to see.

You have a few options here. One method is to create a Page Template, customize that template – replacing the sidebar with whatever you’d like – and select it as the page template for the Checkout page.

A quicker but less elegant solution is to open up page.php, find get_sidebar(); and replace it with something like this (just be sure that checkout is the page’s slug):

That piece of code is basically checking if we’re on the checkout page. If not, it’ll display the sidebar as per usual, but if we are, it’ll do something special. You can see an example of this method being used on the checkout page for Captain Theme.

The checkout page is one of the most crucial pages on an e-commerce site so make sure yours is as effective as possible.

Write a Comment