Skip to content

Instantly share code, notes, and snippets.

@dancameron
Created September 8, 2014 22:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dancameron/298f8954e419dc909fda to your computer and use it in GitHub Desktop.
Save dancameron/298f8954e419dc909fda to your computer and use it in GitHub Desktop.
EDD Recurring Payments & Discounts
<?php
function modify_edd_get_cart_content_details_item_discount_amount( $discount, $item ) {
// We are only worried about SI at this point.
if ( $item['id'] == 49 ) {
// Don't apply a discount since it should come off the signupfee.
return 0;
}
return $discount;
}
add_filter( 'edd_get_cart_content_details_item_discount_amount', 'modify_edd_get_cart_content_details_item_discount_amount', 10, 2 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment