Skip to content

Instantly share code, notes, and snippets.

View BenjaminNelan's full-sized avatar
⌨️
Already had a function that did that.

Benjamin Nelan BenjaminNelan

⌨️
Already had a function that did that.
View GitHub Profile
@BenjaminNelan
BenjaminNelan / functions.php
Last active September 9, 2017 01:52 — forked from woogist/functions.php
Fixes issue with WooCommerce Subscription Orders using PayPal to break during scheduling
function wc_subscriptions_custom_price_string( $pricestring ) {
global $product;
$products_to_change = array( 45, 90, 238 );
if ( method_exists( $product, 'get_id' ) && in_array( $product->get_id(), $products_to_change ) ) {
$pricestring = str_replace( 'every 3 months', 'per season', $pricestring );
}
return $pricestring;