Обновлено - Попробуйте следующее:
add_filter( 'woocommerce_subscriptions_product_price_string', 'subscriptions_custom_price_string', 20, 3 );
function subscriptions_custom_price_string( $price_string, $product, $args ) {
// Get the trial length to check if it's enabled
$trial_length = get_post_meta( $product->get_id(), '_subscription_trial_length', true );
$speriod = get_post_meta( $product->get_id(), '_subscription_period', true );
$sfee = get_post_meta( $product->get_id(), '_subscription_sign_up_fee', true );
$sfee = wc_price($sfee);
$sign_up_fee = isset($args['sign_up_fee']) ? __(" and a $sfee sign-up fee", "woocommerce") : '';
if( $trial_length > 0 )
$price_string = $args['price'] . ' / ' . $speriod . $sign_up_fee;
return $price_string;
}
Код входит в файл function.php вашей активной дочерней темы (или активной темы).Проверено и работает.