Today we received a report from a customer that her WooCommerce checkout was malfunctioning, preventing her own customers from completing the checkout process. After some investigation we were able to determine that the issue is specific to the latest version of WooCommerce (2.3.6) and only affects visitors using Internet Explorer (versions 10 and 11 in our testing).
We found a few reports on the WordPress.org support forums and an issue on the WooCommerce GitHub project. We trust that this issue will be resolved in v2.3.7 and expect that fix will come relatively soon.
In the meantime, however, this bug is losing sales for the affected sites:
“The check box for the state comes up and will not go away, even after you enter the state. This prevented me from going further on my order. I tried many times and then gave up.”
Normally, when a version update introduces a serious bug like this, we would recommend downgrading until the bug has been addressed. However, as v2.3.6 addresses a recently disclosed security vulnerability, downgrading isn’t an option in this case.
A way to fix the issue by modifying WooCommerce core files was outlined on the forums and in the GitHub issue tracker, but core file modification is never recommended – and, luckily, isn’t required in this case. Instead, the woocommerce_get_country_locale
filter can be used:
add_filter( 'woocommerce_get_country_locale', 'gowp_fix_wp_issue_7729', 99 ); function gowp_fix_wp_issue_7729( $locales ) { if ( 'specific' == get_option( 'woocommerce_allowed_countries' ) ) { $countries = get_option( 'woocommerce_specific_allowed_countries' ); foreach ( $countries as $country ) { $locales[$country]['state']['placeholder'] = ""; } } else { foreach ( $locales as $key => $locale ) { $locales[$key]['state']['placeholder'] = ""; } } return $locales; }
The above code can be added to the functions.php of your active theme temporarily.
Note: If you’re a GoWP support and/or hosting customer, this fix has already been applied for you!
Edit (2015/03/18): WooCommerce has fixed this in version 2.3.7 which is now available in the repo. Once you’re updated to this version the patch above can be safely removed.
So, how do I install the “plugin” I am not ready to upgrade to 2.3.7 yet…
Hi Sarah! You can download the plugin using this link: https://github.com/GoWP/woocommerce-236-fixie/archive/master.zip
Then, in your WordPress admin dashboard, navigate to “Plugins > Add New”, click on the “Upload Plugin” button, choose the zip file you downloaded from the link above and then activate the plugin once installed.
The plugin will only apply the fix while WooCommerce is using version 2.3.6. Once you’ve updated to 2.3.7 you can remove the plugin.
Let us know if you have any questions!