Created
July 7, 2024 14:51
-
-
Save shameemreza/dec5e20d8faa805833c51393f0ad954e to your computer and use it in GitHub Desktop.
Change the currency symbol in WooCommerce
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function filter_woocommerce_currency_symbol( $currency_symbol, $currency ) { | |
// Compare | |
switch( $currency ) { | |
case 'GBP': $currency_symbol = '€'; | |
break; | |
} | |
return $currency_symbol; | |
} | |
add_filter( 'woocommerce_currency_symbol', 'filter_woocommerce_currency_symbol', 1, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment