Easy Digital Downloads 2.8 beta 1 available for testing

It’s been a few months since our last major release for Easy Digital Downloads (ok, four and a half to be exact), but today we’re excited to announce that the first beta of Release 2.8 is ready for general testing. While there were a large number of bugs fixed, there was a primary focus of refining the experience of our existing feature set.

Testing the beta

To ensure that the update to version 2.8 goes smoothly, we need as many people as possible to help test the beta. Every bug that we catch between now and the final release is one less problem for live sites.

Please do not test this beta on a live site. We highly recommend using a staging site. You can find our guide to set up a local testing environment here.

The latest version of the beta may be downloaded from GitHub.

Improved variable pricing

If you run an EDD store that uses extensions that add fields and options to the variable pricing, you’ve likely seen something like this when editing a download:

The old variable pricing display with Recurring Payments and Software Licensing enabled.

In version 2.8, we’ve completely re-written the variable pricing options display to be more flexible and scale with any screen size. And the best part, it’s backwards compatible. This means that extensions using the existing hooks and filters will work seamlessly with the 2.8 release, giving developers a chance to update their extensions to the new method (see below).

The new variable pricing display with Recurring Payments and Software Licensing enabled.

Going forward, developers can use the new edd_download_price_option_row action to output their variable price options. Here is an example of how to integrate with the new advanced variable price options user interface:

Purchase button quantity improvements

If quantities are enabled for a product, Easy Digital Downloads will now update the purchase button price to match that of the quantity.

We’ve written this feature in such a way that it is flexible enough to work on most themes without any changes needed by the developers.

Filter payments by gateway

From time to time, it’s useful to view payments made through a specific gateway. In Easy Digital Downloads 2.8, you now have the ability to choose a gateway and filter the Payments list table by the chosen gateway.

Delayed payment actions

From its inception, Easy Digital Downloads has been built around the concept of extensibility. It’s what has lead our platform to have over 250 official add-ons and themes. Over time, as more and more extensions began performing actions after a payment is completed, the checkout process may not seem to complete as quickly. Most of these actions are not ones that are ‘required’ for the purchase to be completed. Things like administrative emails, push notifications, commissions emails, and many other integrations can be delayed slightly as to not affect the purchase completion process. In version 2.8 we’re introducing ‘After Payment’ actions. This new ‘non-transactional’ hook acts exactly like the edd_complete_purchase action that has been previously used for these types of integrations, including the same parameters. So for developers wanting to integrate with the new processing method, it could be as simple as changing the hook you are using.

The hook (edd_after_payment_actions) triggers via WP_Cron just a short time after the payment is marked as completed. Because it fires with WP_Cron, this means that process intensive activities do not affect a user’s load time of your site. Here is an example of how you can use this in your integrations:

There is a filter if you choose not to use after action hooks, and it also respects people who use the WP_DISABLE_CRON constant, in which case, EDD will fallback and perform the actions at the time of completion, and avoid the delayed process.

Key points about after payment actions
  • Triggers via WP_Cron
  • Able to be disabled via filter or WP_DISABLE_CRON
  • By default, it is scheduled for 30 seconds after the purchase, but can be changed via a filter.
  • A post_meta key of _edd_complete_actions_run is stored for the payment to report when the action run (in GMT)
  • A payment note is recorded stating the actions were run.

NOTICE: Because this ‘after payment actions’ system is dependent on WP_Cron, it should not be used for things considered ‘mission critical’. It’s simply a way to offload expensive integrations with APIs and large sets of data that do not directly affect the purchase data.


Other notable enhancements

  • Payment and Customer objects added to payment completion actions #5689
  • Moved edd-ajax.min script to footer #4401
  • Added delete_meta and add_meta methods to EDD_Payment #5744
  • Added filter to output of variable prices #5754
  • Ability to block emails by TLD #5440
  • Improvements to the WP_CLI integration for creating payments #5798
  • Use document.body in our JavaScript when possible, to improve performance #5782
  • Introduced the EDD_Customers_Query class #5448
  • Changed PayPal ‘Page Style’ setting with ‘Image URL’ #5291

There are other enhancements and bugs that have been addressed. You can see a full list on GitHub.

As of Easy Digital Downloads 2.8, the minimum WordPress version supported is WordPress 4.4. While we do not intentionally change anything to break on older versions of WordPress, in order to keep running our automated unit testing and continuous integration tasks efficiently, we need to limit the number of different platforms we test on. Moving forward we will be running our automated unit tests on the following WordPress versions: 4.4, 4.5, 4.6, 4.7, and Latest (4.8.x). We have also dropped the HHVM server from our automated testing, to follow suit with WordPress Core.

One response... add one

Leave a Reply

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