This file contains hidden or 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
| add_action( 'woocommerce_single_product_summary', 'ec_child_wrap_single_product_price', 24 ); | |
| add_action( 'woocommerce_single_product_summary', 'electro_child_adsw_currency_switcher', 26 ); | |
| function ec_child_wrap_single_product_price() { | |
| ?><div class="price-adsw-currency-switcher" style="display: flex; align-items: center;"><?php | |
| } | |
| function electro_child_adsw_currency_switcher() { | |
| echo '<div style="margin-left:15px;">' . do_shortcode( '[adsw_currency_switcher]' ) . '</div>'; | |
| ?></div><!-- /.price-adsw-currency --><?php |
This file contains hidden or 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
| add_filter( 'woocommerce_get_price_html', 'electro_price_prefix_text', 100, 2 ); | |
| function electro_price_prefix_text( $price, $product ){ | |
| $cc = do_shortcode('[adsw_currency_switcher]'); | |
| $price = $price; | |
| return apply_filters( 'woocommerce_get_price', $price .' '.$cc ); | |
| } | |
| add_filter( 'wc_product_sku_enabled', '__return_false' ); |