Your account expired support, please renew to get your support.

Forum Replies Created

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • in reply to: Currecy Switcher #30029
    LeoBalicas
    Support Expired
    This reply has been marked as private.
    in reply to: Currecy Switcher #29998
    LeoBalicas
    Support Expired

    Hi I came back to the original configuration of the code and chose in the woocomerce Geolocation based on page cache and it worked. But you’re still having trouble updating automatically.

    in reply to: Currecy Switcher #29993
    LeoBalicas
    Support Expired

    Hi! I got it! I changed this line of code and BRL stays as default.:

    $client = WC_Geolocation::get_external_ip_address();
    $result = array( ‘currency’ => ” );
    $currencies = Claue_Addons_Currency::getCurrencies();
    $default = Claue_Addons_Currency::woo_currency();

    $ip_data = @json_decode(file_get_contents( ‘http://www.geoplugin.net/json.gp?ip=’ . $client ) );
    if ( $ip_data && $ip_data->geoplugin_currencyCode != null ) {
    $result[‘currency’] = $ip_data->geoplugin_currencyCode;
    if ( isset( $currencies[$result[‘<strong style=”color: red;”>current‘]] ) ) {
    $default = $result;
    }
    }

     

    But there is a problem, even without doing this when I change currency the price does not change automatically, I have to choose another page / product to see the price in the chosen currency.

    I changed ‘<strong style=”color: orange;”>currency‘ for ‘<strong style=”color: red;”>current‘ and it worked

    Do you have any lines of code for this?

    and one more thing, where do I put this changed code in the me child theme? in functions.php or do I copy the path of the original file?

    in reply to: Cart Popup #29890
    LeoBalicas
    Support Expired
    This reply has been marked as private.
Viewing 4 posts - 1 through 4 (of 4 total)