Force account creation for a specific pricing option

Easy Digital Downloads has a “Disable Guest Checkout” option which when enabled, forces customers to create an account before they can make a purchase. On the AffiliateWP website, we only wanted customers to be forced to create an account when they purchased a developer license. Creating an account for either the personal or business license …

Show user’s purchase history as a dashboard widget

By default, when a user registers via the checkout, they are automatically logged in and can access the WordPress’ dashboard as a subscriber. This snippet adds a customer’s purchase history as a dashboard widget. Copy and paste the following functions (mind the opening PHP tag) into your child theme’s functions.php or custom plugin. View the …

How to change a payment gateway’s checkout label in Easy Digital Downloads

This tutorial will show you how you can change a payment gateway’s checkout label. This is the text that appears next to the radio input when there are multiple payment options. For example, if you’re using the 2Checkout payment gateway, the checkout label says “2Checkout” by default. You might like to change this to “Credit …

How to add custom text before the purchase button at checkout

This quick snippet will show you how to add some custom text just before the purchase button at checkout. The 1000 in the add_action function represents the priority. The Purchase Total that shows just before the purchase button has a priority of 999, so if you’d like your text to appear before that, change the priority to something lower. …