Skip to content

Instantly share code, notes, and snippets.

@SeanChDavis
Created July 31, 2014 02:38
Show Gist options
  • Select an option

  • Save SeanChDavis/161dbb254600948d3f5a to your computer and use it in GitHub Desktop.

Select an option

Save SeanChDavis/161dbb254600948d3f5a to your computer and use it in GitHub Desktop.
EDD Double Purchase Buttons
<?php
/**
* add "Buy Now" button below Add to Cart button on single downloads
*/
function custom_buy_now_button() { ?>
<a href="<?php echo edd_get_checkout_uri() . '?edd_action=add_to_cart&download_id=' . get_the_ID(); ?>">Buy Now</a>
<?php }
add_action( 'edd_purchase_link_end', 'custom_buy_now_button' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment