{"id":389,"date":"2017-06-29T16:16:51","date_gmt":"2017-06-29T21:16:51","guid":{"rendered":"https:\/\/easydigitaldownloads.com\/development\/?p=389"},"modified":"2021-12-15T15:30:57","modified_gmt":"2021-12-15T21:30:57","slug":"easy-digital-downloads-2-8-beta-1-available-for-testing","status":"publish","type":"post","link":"https:\/\/easydigitaldownloads.com\/development\/2017\/06\/29\/easy-digital-downloads-2-8-beta-1-available-for-testing\/","title":{"rendered":"Easy Digital Downloads 2.8 beta 1 available for testing"},"content":{"rendered":"<p>It&#8217;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&#8217;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.<\/p>\n<h3>Testing the beta<\/h3>\n<p>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.<\/p>\n<p><strong>Please do not test this beta on a live site. We highly recommend using a <a href=\"https:\/\/easydigitaldownloads.com\/blog\/staging-site-e-commerce\/\">staging site<\/a>. You can find our guide to set up a\u00a0local testing environment <a href=\"https:\/\/easydigitaldownloads.com\/blog\/a-testing-server-the-easy-way\/\">here<\/a>.<\/strong><\/p>\n<p>The latest version of the beta may be <a href=\"https:\/\/github.com\/easydigitaldownloads\/easy-digital-downloads\/archive\/2.8-beta1.zip\" target=\"_blank\" rel=\"noopener\">downloaded from GitHub<\/a>.<\/p>\n<h3>Improved variable pricing<\/h3>\n<p>If you run an EDD store that uses extensions that add fields and options to the variable pricing, you&#8217;ve likely seen something like this when editing a download:<\/p>\n<figure id=\"attachment_390\" aria-describedby=\"caption-attachment-390\" style=\"width: 905px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-390 size-full\" src=\"https:\/\/easydigitaldownloads.com\/development\/files\/2017\/06\/edd-variable-pricing-old.png\" alt=\"\" width=\"905\" height=\"395\" srcset=\"https:\/\/easydigitaldownloads.com\/development\/files\/2017\/06\/edd-variable-pricing-old.png 905w, https:\/\/easydigitaldownloads.com\/development\/files\/2017\/06\/edd-variable-pricing-old-300x131.png 300w, https:\/\/easydigitaldownloads.com\/development\/files\/2017\/06\/edd-variable-pricing-old-768x335.png 768w\" sizes=\"auto, (max-width: 905px) 100vw, 905px\" \/><figcaption id=\"caption-attachment-390\" class=\"wp-caption-text\">The old variable pricing display with Recurring Payments and Software Licensing enabled.<\/figcaption><\/figure>\n<p>In version 2.8, we&#8217;ve completely re-written the variable pricing options display to be more flexible and scale with any screen size. And the best part, it&#8217;s <em><strong>backwards compatible<\/strong><\/em>. This means that extensions using\u00a0the 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).<\/p>\n<figure id=\"attachment_391\" aria-describedby=\"caption-attachment-391\" style=\"width: 951px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-391\" src=\"https:\/\/easydigitaldownloads.com\/development\/files\/2017\/06\/edd-variable-pricing-new.png\" alt=\"\" width=\"951\" height=\"563\" srcset=\"https:\/\/easydigitaldownloads.com\/development\/files\/2017\/06\/edd-variable-pricing-new.png 951w, https:\/\/easydigitaldownloads.com\/development\/files\/2017\/06\/edd-variable-pricing-new-300x178.png 300w, https:\/\/easydigitaldownloads.com\/development\/files\/2017\/06\/edd-variable-pricing-new-768x455.png 768w\" sizes=\"auto, (max-width: 951px) 100vw, 951px\" \/><figcaption id=\"caption-attachment-391\" class=\"wp-caption-text\">The new variable pricing display with Recurring Payments and Software Licensing enabled.<\/figcaption><\/figure>\n<p>Going forward, developers can use the new <code>edd_download_price_option_row<\/code> action to output their variable price options. Here is an example of how to integrate with the new advanced variable price options user interface:<br \/>\nhttps:\/\/gist.github.com\/cklosowski\/09492ad45281b64b54a8e0c1dfdca83e<\/p>\n<h3>Purchase button quantity improvements<\/h3>\n<p>If quantities are enabled for a product, Easy Digital Downloads will now update the purchase button price to match that of the quantity.<br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-394\" src=\"https:\/\/easydigitaldownloads.com\/development\/files\/2017\/06\/edd-quantity-purchase-link-update.gif\" alt=\"\" width=\"367\" height=\"159\" \/><br \/>\nWe&#8217;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.<\/p>\n<h3>Filter payments by gateway<\/h3>\n<p>From time to time, it&#8217;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.<br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-396\" src=\"https:\/\/easydigitaldownloads.com\/development\/files\/2017\/06\/edd-filter-payments-by-gateway.png\" alt=\"\" width=\"711\" height=\"189\" srcset=\"https:\/\/easydigitaldownloads.com\/development\/files\/2017\/06\/edd-filter-payments-by-gateway.png 711w, https:\/\/easydigitaldownloads.com\/development\/files\/2017\/06\/edd-filter-payments-by-gateway-300x80.png 300w\" sizes=\"auto, (max-width: 711px) 100vw, 711px\" \/><\/p>\n<h3>Delayed payment actions<\/h3>\n<p>From its inception, Easy Digital Downloads has been built around the concept of extensibility. It&#8217;s what has lead our platform to have <a href=\"https:\/\/easydigitaldownloads.com\/downloads\/\">over 250 official add-ons and themes<\/a>.\u00a0Over time, as more and more extensions began performing actions after a payment is completed, the checkout process may not seem to complete as quickly.\u00a0Most of these actions are not ones that are &#8216;required&#8217; 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&#8217;re introducing &#8216;After Payment&#8217; actions. This new &#8216;non-transactional&#8217; hook acts exactly like the <code>edd_complete_purchase<\/code> 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.<\/p>\n<p>The hook\u00a0(<code>edd_after_payment_actions<\/code>) 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&#8217;s load time of your site. Here is an example of how you can use this in your integrations:<br \/>\nhttps:\/\/gist.github.com\/cklosowski\/ad335921cf40a6d7e315043e95b1e7d5<\/p>\n<p>There is a filter if you choose not to use after action hooks, and it also respects people who use the <code>WP_DISABLE_CRON<\/code> constant, in which case, EDD will fallback and perform the actions at the time of completion, and avoid the delayed process.<\/p>\n<h5>Key points about after payment actions<\/h5>\n<ul>\n<li>Triggers via WP_Cron<\/li>\n<li>Able to be disabled via filter or WP_DISABLE_CRON<\/li>\n<li>By default, it is scheduled for 30 seconds after the purchase, but can be changed via a filter.<\/li>\n<li>A post_meta key of <code>_edd_complete_actions_run<\/code> is stored for the payment to report when the action run (in GMT)<\/li>\n<li>A payment note is recorded stating the actions were run.<\/li>\n<\/ul>\n<p class=\"edd-alert edd-alert-warn\"><strong>NOTICE:<\/strong> Because this &#8216;after payment actions&#8217; system is dependent on WP_Cron, it should not be used for things considered &#8216;mission critical&#8217;. It&#8217;s simply a way to offload expensive integrations with APIs and large sets of data that do not directly affect the purchase data.<\/p>\n<p>&nbsp;<\/p>\n<h3>Other notable enhancements<\/h3>\n<ul>\n<li>Payment and Customer objects added to payment completion actions <a href=\"https:\/\/github.com\/easydigitaldownloads\/easy-digital-downloads\/issues\/5689\">#5689<\/a><\/li>\n<li>Moved edd-ajax.min script to footer\u00a0<a href=\"https:\/\/github.com\/easydigitaldownloads\/easy-digital-downloads\/issues\/4401\">#4401<\/a><\/li>\n<li>Added delete_meta and add_meta methods to EDD_Payment <a href=\"https:\/\/github.com\/easydigitaldownloads\/easy-digital-downloads\/issues\/5744\">#5744<\/a><\/li>\n<li>Added filter to output of variable prices <a href=\"https:\/\/github.com\/easydigitaldownloads\/easy-digital-downloads\/issues\/5754\">#5754<\/a><\/li>\n<li>Ability to block emails by TLD <a href=\"https:\/\/github.com\/easydigitaldownloads\/easy-digital-downloads\/issues\/5440\">#5440<\/a><\/li>\n<li>Improvements to the WP_CLI integration for creating payments <a href=\"https:\/\/github.com\/easydigitaldownloads\/easy-digital-downloads\/issues\/5798\">#5798<\/a><\/li>\n<li>Use document.body in our JavaScript when possible, to improve performance <a href=\"https:\/\/github.com\/easydigitaldownloads\/easy-digital-downloads\/pull\/5782\">#5782<\/a><\/li>\n<li>Introduced the EDD_Customers_Query class <a href=\"https:\/\/github.com\/easydigitaldownloads\/easy-digital-downloads\/issues\/5448\">#5448<\/a><\/li>\n<li>Changed PayPal &#8216;Page Style&#8217; setting with &#8216;Image URL&#8217; <a href=\"https:\/\/github.com\/easydigitaldownloads\/easy-digital-downloads\/issues\/5291\">#5291<\/a><\/li>\n<\/ul>\n<p>There are other enhancements and bugs that have been addressed. You can<a href=\"https:\/\/github.com\/easydigitaldownloads\/easy-digital-downloads\/milestone\/124\"> see a full list on GitHub<\/a>.<\/p>\n<p class=\"edd-alert edd-alert-info\">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: <strong>4.4, 4.5, 4.6, 4.7, and Latest (4.8.x)<\/strong>. We have also dropped the HHVM server from our automated testing, to follow suit with WordPress Core.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>It&#8217;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&#8217;re excited to announce that the first beta of Release 2.8&#8230;<\/p>\n<p class=\"continue-reading\"><a class=\"more-link\" href=\"https:\/\/easydigitaldownloads.com\/development\/2017\/06\/29\/easy-digital-downloads-2-8-beta-1-available-for-testing\/\">Continue reading &rarr;<\/a><\/p>\n","protected":false},"author":650,"featured_media":418,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[4],"tags":[],"class_list":["post-389","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-core"],"_links":{"self":[{"href":"https:\/\/easydigitaldownloads.com\/development\/wp-json\/wp\/v2\/posts\/389","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/easydigitaldownloads.com\/development\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/easydigitaldownloads.com\/development\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/easydigitaldownloads.com\/development\/wp-json\/wp\/v2\/users\/650"}],"replies":[{"embeddable":true,"href":"https:\/\/easydigitaldownloads.com\/development\/wp-json\/wp\/v2\/comments?post=389"}],"version-history":[{"count":10,"href":"https:\/\/easydigitaldownloads.com\/development\/wp-json\/wp\/v2\/posts\/389\/revisions"}],"predecessor-version":[{"id":1109,"href":"https:\/\/easydigitaldownloads.com\/development\/wp-json\/wp\/v2\/posts\/389\/revisions\/1109"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/easydigitaldownloads.com\/development\/wp-json\/wp\/v2\/media\/418"}],"wp:attachment":[{"href":"https:\/\/easydigitaldownloads.com\/development\/wp-json\/wp\/v2\/media?parent=389"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/easydigitaldownloads.com\/development\/wp-json\/wp\/v2\/categories?post=389"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/easydigitaldownloads.com\/development\/wp-json\/wp\/v2\/tags?post=389"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}