WordPress filter hook
yay_currency_revert_price
Fired by 4 WordPress plugins, running on 28K+ sites between them.
How to use yay_currency_revert_price
It's a filter: your callback receives the value and 1 more argument, and must return the (changed) value.
Add this to your theme's functions.php or a small custom plugin:
add_filter( 'yay_currency_revert_price', function( $value, $arg2 ) {
// Change $value here.
return $value;
}, 10, 2 );Argument names come from Wallet for WooCommerce's source. Other plugins may pass different values: check the call in the plugin you're targeting below.
4 plugins that fire yay_currency_revert_price
Sorted by active installs. Each entry shows where the plugin calls the hook and what it passes.
-
Wallet for WooCommerce20,000+ installs
apply_filters( 'yay_currency_revert_price', (float) $amount, array() )includes/multicurrency/providers/class-woo-wallet-currency-provider-yaycurrency.php:186 -
YayCurrency7,000+ installs
apply_filters( 'yay_currency_revert_price', $wapf_item_price['options_total'], $apply_currency )includes/Engine/Compatibles/AdvancedProductFieldsForWooCommerce.php:95 -
Quantity Discounts, Breaks & Product Bundles for Woocommerce By Bundler400+ installs
apply_filters( 'yay_currency_revert_price', $price )src/integrations/yay-currency.php:139 -
Product Option Kit400+ installs
apply_filters( 'yay_currency_revert_price', $price, '' )includes/Pricing/Currency/Adapter/YayCurrencyAdapter.php:44
Need a customisation built on this hook?
Tell us what you want to change and which plugin it's for. We'll write it, test it and send it back as a small plugin.