The $options variable in product-subscription-options.php, by default, does not contain anything useful in order to customise the output with template overrides.
The array just needs the product price and sale price adding as values, and for these to update on selecting a variation.
This data is already pulled through somewhere in the function that generates this array, and when changing the variation, as it is included in the description of a subscription. It just needs to be included as individual options too.
Open
Last updated: May 19, 2022
Log in to comment on this feature request.
This is easily added by including the below in the options arrays in class-wcs-att-display-product.php – 2 second task, but unless WC Developers add it, the plugin can’t be updated!
‘product_price’ => $product->get_regular_price(),
‘price’ => $product->get_price()
This is a SIMPLE change, creating VAST opportunities for developers to customise the output of the subscription options.
No idea why it hasn’t been added as standard.
Looking into this further, the filters within the file are not firing again when changing a variation.
They run on first load, but don’t run again after changing a variation, but the rest of the function in the plugin is loading which in turn reload the prices when coded within the plugin file, but not running the filters in the theme hooked into the function.