Home
›
COMPATIBILITY
›
Giftware - WooCommerce Gift Cards
Giftware - WooCommerce Gift Cards
Plugin link : https://makewebbetter.com/product/giftware-woocommerce-gift-cards/
In file \wp-content\plugins\woocommerce-ultimate-gift-card\function\woocommerce-ultimate-gift-card-function.php add next code:
if (class_exists('WOOCS')) {
global $WOOCS;
$currency = $WOOCS->current_currency;
$currencies = $WOOCS->get_currencies();
$rate = $currencies[$currency]['rate'];
if (isset($_POST['mwb_wgm_price']) AND floatval($_POST['mwb_wgm_price']) != 0.0) {
$_POST['mwb_wgm_price'] = floatval($_POST['mwb_wgm_price']) / $rate;
}
}
$rate = 1;
if (class_exists('WOOCS')) {
global $WOOCS;
//$order_id=$item->get_order_id();
//$order_currency = get_post_meta($order_id, ‘_order_currency’, true);
//woocs
$order_currency = $WOOCS->current_currency;
$currencies = $WOOCS->get_currencies();
$rate = $currencies[$order_currency]['rate'];
}
$total_discount = $mwb_ugc_discount/$rate;
$total_discount = $mwb_ugc_discount/$rate;
if (class_exists('WOOCS')) {
global $WOOCS;
$cur_cur = $WOOCS->current_currency;
$WOOCS->reset_currency();
$args['amount'] = wc_price($mwb_wgm_common_arr['couponamont']);
$WOOCS->set_currency($cur_cur);
}
//woocs
$currency_symbol = get_woocommerce_currency_symbol();
if (class_exists('WOOCS')) {
global $WOOCS;
$currency = $WOOCS->default_currency;
$currencies = $WOOCS->get_currencies();
$currency_symbol = $currencies[$currency]['symbol'];
}
$message = str_replace('COUPONAMOUNT', $currency_symbol . $remaining_amount, $message);
← Gift Cards for WooCommerce by Woo
Google for WooCommerce →
🌸
Shortcodes, functions, actions and filters reference for FOX WooCommerce Currency Switcher
Codex — FOX Currency Switcher
Got it
We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.