Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function wc_subscriptions_custom_price_string( $pricestring ) {
- global $product;
- $products_to_change = array( 170, 215, 312 );
- if ( in_array( $product->id, $products_to_change ) ) {
- $pricestring = 'Current year dues are ' . wc_price( $product->subscription_sign_up_fee ) .
- ', with recurring annual dues of ' . wc_price( $product->subscription_price );
- }
- return $pricestring;
- }
- add_filter( 'woocommerce_subscription_price_string', 'wc_subscriptions_custom_price_string', 10, 3 );
- add_filter( 'woocommerce_subscriptions_product_price_string', 'wc_subscriptions_custom_price_string', 10, 3 );
Add Comment
Please, Sign In to add comment