WooCommerce Free Shipping Threshold Not Working: Decimal Formatting Issue

In a recent Business Bloomer Club Slack thread, a user shared an unexpected issue with WooCommerce’s free shipping functionality.

They had configured a free shipping threshold of €200 in their webshop, yet encountered inconsistencies: free shipping applied correctly for some products but failed for others, even when these items exceeded the set amount.

Continue reading WooCommerce Free Shipping Threshold Not Working: Decimal Formatting Issue

WooCommerce: Email Admin Upon Fatal Error

WooCommerce has a nice feature when it comes to WordPress Error 500 / Fatal Error – it logs the error and all the information regarding it inside the WooCommerce Status > Logs > Fatal Errors area.

My problem is that sometimes these errors occur in the backend, so they may not trigger the WordPress built-in email that notifies the admin about the problem.

What I want to try (please test it on your development website first, and not on your live website), is a way to get an email each time WooCommerce logs an error, so that I can go in and fix it immediately. Enjoy!

Continue reading WooCommerce: Email Admin Upon Fatal Error

WooCommerce: Fix “Sorry, This File Type Is Not Permitted for Security Reasons” For Downloadable Products

In WordPress, you get the “Sorry, This File Type Is Not Permitted for Security Reasons” error when you try to upload certain files to the Media library. Similarly, in WooCommerce you may get the same error when you try to upload a downloadable product download files.

Why is that? Well, by default WordPress only allows certain file extensions to be uploaded to the site. For example PNG, JPG, PDF, PPT, DOC, MP3 and MP4 are within the allowed file types – the reason being they are “safe” and won’t contain malicious code that could create problems within a WordPress install.

The thing is – I’ve started selling my first downloadable product (a mini-plugin) here on Business Bloomer and I needed to upload a ZIP file (the mini-plugin), a JSON file (a Code Snippet export file for those who don’t like plugins) and a TXT file (the plugin’s raw code for those who like to play with PHP). All went smoothly for the ZIP upload, but as soon as I tried uploading the JSON and TXT files I got the “Sorry, This File Type Is Not Permitted for Security Reasons” error.

Panic? Not really. It’s only a matter of finding the right code to change this default WordPress behavior. So, say hello to the “upload_mimes” filter, which allows us to do just that. Enjoy!

Continue reading WooCommerce: Fix “Sorry, This File Type Is Not Permitted for Security Reasons” For Downloadable Products

WordPress: Fix “No Update Required” @ WP Admin

It happened to me today while updating to WordPress 5.3, so I thought of sharing the fix with all the people who are going to have this problem now and in the future.

Honestly, I should have thought about this better – but it’s an early Saturday morning and maybe my brain is still asleep.

I kept getting always the same error, even after 10 refreshes and attempts, even while trying to use /wp-login.php or /my-account to login as opposed to /wp-admin. And when you get the same behavior no matter how many times you refresh or try again… well, it should be easy to understand why!

Continue reading WordPress: Fix “No Update Required” @ WP Admin

WooCommerce: “uploaded file exceeds the upload_max_filesize” Error

upload-max-file-size wordpress

You may have seen this error at least once, if you have used WordPress. When installing a theme, plugin or uploading a image or file, you may find this dreaded message on your screen.

Well, it has nothing to do with themes or plugins. The issue is with your server settings which limit the maximum size for uploaded files.

It’s a common error and it can be easily fixed. This error message is an indication of that the file you are trying to upload is larger than your web host allows (WordPress default file upload size is 2 MB).

Continue reading WooCommerce: “uploaded file exceeds the upload_max_filesize” Error