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 Card”.

All of the payment gateways built for Easy Digital Downloads should be using a filter called edd_payment_gateways┬áto register their gateway’s text labels for both the admin and checkout page. You’ll need to look inside the plugin to get the exact value for which the plugin has registered itself under as shown in the example below. This can easily be done by searching for the filter name.

The code

Copy and paste the following function (mind the opening PHP tag) into your child theme’s functions.php or custom plugin:

Here’s another example of changing the text, but this time for the Check payment gateway. A customer of the EDD forums requested “Checks” be “Bank Deposit”.

3 thoughts on “How to change a payment gateway’s checkout label in Easy Digital Downloads”

  1. Nice! Very useful!

    I used to change the .mo file, but some plugins don’t support translations on your theme’s folder, and I lost my translations every time I updated the plugin… this code is really helpful.

    Thanks Andrew!

Leave a Reply

Your email address will not be published. Required fields are marked *