PluginUs.Net - Business Tools for WooCommerce and WordPress

[realize your idea - make your dreams come true]

Support Forum

You need to log-in to create request (topic) to the support

woocommerce product addon with fox currency

The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday. If you have problems with registration ask help on contact us page please
If you not got email within 24~36 business hours, firstly check your spam box, and if no any email from the support there - back to the forum and read answer here. DO NOT ANSWER ON EMAILS [noreply@pluginus.net] FROM THE FORUM!! Emails are just for your info, all answers should be published only here.
The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday.
12

Hello

Please try  to  paste  this  code( All the code I made for adaptation ) - https://share.pluginus.net/image/i20240621135611.png - and do a test

Hi Pablo

Could you please make the code so i can copy/paste thanks

Ole

Hello Ole

You will find all the code in this topic - https://share.pluginus.net/image/i20240621135611.png

Hi Pablo

I have tried add your code to staging.tibladin.dk, but cant see this issue i solved, sorry

regards

Ole

 

Hello Ole

Great! Welcome;)

 

Hi Pablo

I write this: but can't see this issue i solved, sorry

regards

ole

Hello Ole

Ok! I  will  check it

Hello Ole

I checked the third-party plugin code. You didn't add the adaptation code( not all code ).

If you don't have any programming experience, you should hire a developer to add this code.

 

Hi Pablo

I have added this code and followed where to place the code, is this wrong

In file wp-content\plugins\woocommerce-product-addons\includes\class-wc-product-addons-cart.php add next code: https://share.pluginus.net/image/i20240531181742.png

if ($addon['price'] AND class_exists('WOOCS')) {
global $WOOCS;
$currrent = $WOOCS->current_currency;
if ($currnent != $WOOCS->default_currency AND $WOOCS->is_multiple_allowed) {
$currencies = $WOOCS->get_currencies();
$rate = $currencies[$currnent]['rate'];
$addon['price'] = $addon['price'] * $rate;
}
}

 

Also in the same file add code: https://share.pluginus.net/image/i20240531182106.png

if (class_exists('WOOCS')) {
global $WOOCS;
$currrent = $WOOCS->current_currency;
if ($currnent != $WOOCS->default_currency AND $WOOCS->is_multiple_allowed) {
$currencies = $WOOCS->get_currencies();
$rate = $currencies[$currnent]['rate'];
}
}

regards

Ole

This is just part of the code. Now try adding the rest of the code and test it.

 

12