Bobcares

WordPress error cropping image – The way we fix it

by | Aug 26, 2019

Can you imagine your WordPress site without images? Images bring out the personality of any content.

Sometimes when you edit an image before uploading, you will see the message

There has been an error cropping your image.

‘WordPress error cropping image’ mainly happens because of the absence of the GD (Graphics Draw) package.

Today lets see what leads to this error and how our Support Engineers fix this for our customers.

 

How does image cropping error look?

WordPress offer freedom to build websites, hobby blogs, etc. Hence it always includes features to upload images.

Let’s take a look at how the image cropping error look.

To upload an image in WordPress users use the option “Select and Crop”. Then adjust the crop selection, then select “Crop Image”. When things do not work, it shows the message ‘There has been an error cropping your image’. Here, the WordPress “Media Library” turns grey and results in the error.

 

Image displaying error in text formate 'There has been an error cropping your image'.

 

The most common reason leading to the error is missing the PHP-GD library.

Mostly, when we hear about PHP in WordPress, the first thing that we use to relate is HTML. But PHP is also used to create and edit image files. Image formats supported include GIF, PNG, JPEG, WBMP, and XMP.  In general, PHP allows uploading an image directly into the browser. And, it’s the GD library that makes image functions work.

 

How we fix WordPress image cropping error

We now know how the error looks. Moving on further let’s check on how our Support Engineers fix image cropping error for our customers.

As the first step of troubleshooting, we check the server’s PHP version along with the GD package.  If the GD package is missing, we install it. However, the GD installation steps differ depending on the server type.

For RedHat/ CentOS hosts, we run the command

 yum install php-gd

Or, if it is an Ubuntu server, GD installation works using

 apt-get install php-gd

Here, our Support Team also makes sure that the version of the WordPress package matches the PHP version of the host.

Finally, to make the newly installed GD package, the webserver needs a restart. We do this in the server by

/etc/init.d/httpd restart

After fixing the error, in the “Media Library,” the user can select the image and “Insert into post”.

 

Media library after fixing the error

[Need help in fixing WordPress error? We are here 24×7.]

 

Conclusion

In short, the main reason for the WordPress error cropping image will be missing the GD package on the server. Today, we saw how our Support Engineers check and fix image uploading error for our customers.

PREVENT YOUR SERVER FROM CRASHING!

Never again lose customers to poor server speed! Let us help you.

Our server experts will monitor & maintain your server 24/7 so that it remains lightning fast and secure.

GET STARTED

var google_conversion_label = "owonCMyG5nEQ0aD71QM";

8 Comments

  1. Bibek

    Thank you so much, I was finally able to upload a fab-icon in my wordpress site.

    Reply
    • Hiba Razak

      Hi Bibek,
      Glad to know that our article helps you solves the issue ?

      Reply
  2. Patrick Nascimento

    What about Xampp local server? How do we proceed in this case?

    Reply
    • Hiba Razak

      Hello Patrick,
      You can use the same method used in this article in XAMPP server also.

      Reply
  3. Wilson

    Thank you so much, it was really helpful. I had that problem with my xampp server then I noticed that the gd package was commented out.

    Reply
    • Hiba Razak

      Hi Wilson,
      We are glad to know that our article helps you solves the issue ?

      Reply
  4. simo

    thank you very much :*

    Reply
    • Hiba Razak

      Hi ,
      Thanks for the feedback. We are glad to know that our article was helpful for you 🙂 .

      Reply

Submit a Comment

Your email address will not be published. Required fields are marked *

Never again lose customers to poor
server speed! Let us help you.