Forum Replies Created

Viewing 7 replies - 1 through 7 (of 7 total)
  • Hello, I have version 3.4.22 and facing the same issue. The language showing in the backend is the site language, not the user selected language.

    Thank you in advance,
    Miguel.

    Thread Starter Miguel Fernández Corral

    (@mfcorral)

    Hello @ivaylo123, you can add to your style.css file the following code to fix it. Waiting for Flatsome team to fix it in the next version.

    
    body.woocommerce-checkout .woocommerce-account-fields .create-account {
      display: block !important;
    }
    

    Regards,
    Miguel.

    Thread Starter Miguel Fernández Corral

    (@mfcorral)

    Hello and thanks again for the support! I’m going to send the issue to the flatsome team.

    Regards,
    Miguel.

    Thread Starter Miguel Fernández Corral

    (@mfcorral)

    Hello again and thanks for your quick response. I’m using:

    WordPress 4.9.4
    WooCommerce 3.3.1
    YITH WooCommerce Whishlist 2.2.1
    Flatsome 3.5.1

    All of them fresh installed, and only had installed them. No customizations, my style.css and functions.php are empty and no template overrides.

    With that configuration, the create password field in checkout is missing. If I deactivate the wishlist plugin, the field appeares. But if I activate it and change the theme (I tried storefront), the field is visible as well.

    It seems that the wishlist plugin with flatsome theme (or viceversa) have an issue living together.

    Strange, how could I solve this issue?

    Thanks a lot again,
    Miguel.

    Hi, I finally found a solution to order the product variations (in my case, alphabetical) in the frontend (combobox). Here is the code:

    add_filter('woocommerce_dropdown_variation_attribute_options_html', function ($html) {
        $xml = simplexml_load_string($html);
    
        $select = array('id'               => (string)$xml->attributes()['id'],
                        'name'             => (string)$xml->attributes()['name'],
                        'attribute_name'   => (string)$xml->attributes()['data-attribute_name'],
                        'show_option_none' => (string)$xml->attributes()['data-show_option_none']);
    
        $options = array();
        foreach($xml->option as $option) {
            $options[] = array('text'     => (string)$option,
                               'value'    => (string)$option->attributes()['value'],
                               'selected' => (string)$option->attributes()['selected'] === 'selected');
        }
    
        usort($options, function ($a, $b) {
            return strcmp($a['value'], $b['value']);
        });
    
        $xml = simplexml_load_string('<select/>');
        $xml->addAttribute("id", $select["id"]);
        $xml->addAttribute("name", $select["name"]);
        $xml->addAttribute("data-attribute_name", $select["attribute_name"]);
        $xml->addAttribute("data-show_option_none", $select["show_option_none"]);
        
        foreach ($options as $option) {
            $child = $xml->addChild('option');
            $child->value = $option['text'];
            $child->addAttribute('value', $option['value']);
            if ($option['selected']) {
                $child->addAttribute('selected', 'selected');
            }
        }
    
        return $xml->asXML();
    });

    Cheers,
    Miguel.

    Thread Starter Miguel Fernández Corral

    (@mfcorral)

    Muchas gracias por contestar tan rápido. Usaré ese filtro entonces.

    Un saludo,
    Miguel.

    Hi all, I wrote the following code to fix it:

    add_filter("woocommerce_package_rates", function ($rates, $package) {
        $methods = array();
        foreach (array_keys($rates) as $rate) { 
            $methods[preg_replace('/^(.+?):.*/', '${1}', $rate)] = $rate;
        }
        if (in_array("free_shipping", array_keys($methods))) {
            unset($rates[$methods["flat_rate"]]);
        }
        return $rates;
    });

    Best regards,
    Miguel.

Viewing 7 replies - 1 through 7 (of 7 total)