Support » Fixing WordPress » There has been an error cropping your image

Viewing 15 replies - 1 through 15 (of 22 total)
  • Thread Starter anthonykung


    I had already looked through every thread regarding this and that does not help since my PHP version is already at 7.0 as stated above. Clearing caches do not work too.

    • This reply was modified 4 years, 8 months ago by anthonykung.
    Thread Starter anthonykung


    Ah never mind, fixed it. Its the GD Library not installed.

    Here’s the SSH line command to install it:
    sudo apt-get install php7.0-gd
    Use this to stop Apache for it to make changes.
    sudo apachectl stop
    Start Apache now and everything is fixed.
    sudo apachectl start

    Hmm, now that I thought of it, this forum isn’t really helpful as promised.

    now that I thought of it, this forum isn’t really helpful as promised.

    This is a WordPress support forum, run by volunteers.

    And for that, it’s awesome.

    In fact, many people are humbled by the kind of support they receive here for free when their theme/plugin vendors and hosts they’re paying month after month are unable or just refuse to help them.

    It’s not a server administration forum.

    Was your “fix” in anyway related to WordPress at all?

    Thread Starter anthonykung


    It runs on WordPress why else will I ask here, there’s no requirement for this only PHP versions and MySQL. If it’s regarding SSL installation fine it’s not WordPress, but this is WordPress’s Media Library and there’s no manual saying that I should install that. I figure it out myself after studying WordPress functions.php and that suppose to be what a proper “volunteer” should help instead of sending a random link to a thread without considering the WordPress forum rule is to look for similar issues before posting.

    As a WordPress user, I appreciate your help @anthonykung

    @anthonykung or anyone else, could you perhaps help me to understand how to put those commands in? I am having the same problem but I am not a programmer.

    Thread Starter anthonykung


    Sure thing @clarecorker,

    First you need to log into your server using SSH. Simply open Command Prompt (cmd) for Windows or Terminal for Mac and type the following:

    SSH [username]@[server-ip]
    Replace the []
    Then it will ask for password just type it in, for security reasons you won’t see what you’re typing.

    After that you should be logged in and you’ll just have to install the GD library by typing:

    sudo apt-get install php7.0-gd

    Final step is to restart your server, if you’re using Apache2 use apachectl restart if you’re using Nginx try service nginx restart

    Hope this helps.

    Just wanted to say thanks for this. I completely overlooked the missed dependency. You saved me a ton of time.

    @anthonykung, I had this same issue. My question is this: how did you discover which module was missing? I’m running on FreeBSD and apparently lots of PHP modules that are installed by default on Linux are missing here. I’ve had to install quite a few, gd being just the latest. In all other cases, I found errors in the Apache error log for the web page which indicated a missing function. I’d then Google around to find out which PHP module that function is in, add it, restart Apache, and poof, fixed. In this case, however, there was no error listed so I was lost until I found your post. So… how’d you figure it out?



    I’m glad your post has helped others. I do think though that you could have demonstrated a little more courtesy to @gappiah. Like he said, volunteers run this board. Putting @gappiah on the defensive for the community, in my opinion, didn’t help anyone. Also, nowhere do I see a ‘promise’ that anyone will help you here.

    Some might argue that given the level of knowledge you appear to have in your original post, it seems like you must have just overlooked the fact that you would need an image library to manipulate images on the server. Sometimes even just writing down your issue, or talking to another developer can lead you to a solution. Not everyone resolves problems in the same way. This is the human condition, and communication is the catalyst for higher learning. I don’t know maybe you were just in a bad mood, frustrated by the issue you were faced with. I think if you read your post again, you might see my point. If not, that’s ok too.

    At any rate, for those that might stumble upon this thread seeking answers to their own problems. Take a look here if you are having some similar issue like something not working and no error seems to be generated.

    Remember, not everyone is a front-end developer, a back-end developer, a middleware developer, a designer, a Linux expert, a command line cowboy, a server administrator, a DevOps expert, a cms administrator, a website troubleshooting expert, or a volunteer forum contributor.

    But everyone is a person and deserves respect for any assistance they offer to anyone who asks. My hats off to all volunteers and member of this forum. Without you, there would be no support.

    @anthonykung Thank you, your post helped me finally after I wasted around 8 hours fighting with this unknown dependency.

    The problem with this kind of issues is that, wordpress hides the OS error messages and just tells you “there has been problem”. That is a damn dead-end! If there is no proper documentation at codex, I have to google it, search through and filter all the responses for an answer or just read the core code all by yourself and figure it out. If I have so much time, why would I even choose wordpress unless I am making use of some powerful features which are most essential for my site ? For example, for next static site, I would probably go with some Html5 template if I need to do a quick job.
    I can understand the frustration and it is in no way to put down the wonderful help of volunteers do.

    @thorak01 Thank you for your link to stackexchange question, I also found that I need php-ssh2 library. There are many out-dated answers there, so here is a quick summary of what I did. I use wp-cli i.e. wp command line utility on ubuntu.

    $  wp install
    $  wp ext check 
    # This prints all the recommended php extensions.
    | extension | installed |
    | mbstring  |           |
    | ssh2      |           |
    | curl      | 1         |
    | date      | 1         |
    | dom       | 1         |
    | exif      | 1         |
    | filter    | 1         |
    | ftp       | 1         |
    | gd        | 1         |
    | hash      | 1         |
    | iconv     | 1         |
    | imagick   | 1         |
    | json      | 1         |
    | libxml    | 1         |
    | mysqli    | 1         |
    | openssl   | 1         |
    | pcre      | 1         |
    | posix     | 1         |
    | SimpleXML | 1         |
    | sockets   | 1         |
    | SPL       | 1         |
    | tokenizer | 1         |
    | xml       | 1         |
    | xmlreader | 1         |
    | zlib      | 1         |
    sudo apt install php-ssh2
    sudo apt install php-mbstring
    sudo systemctl restart apache2

    Hope this helps few others too.

    I have resolved this issue with WordPress 5.0 ,PHP 7.2 Nginx

    sudo apt-get install php7.2-gd

    sudo systemctl restart nginx

    Now you can check my site its working fine

    Hey thanks… that was a really useful tip. and thanks for resolving your own question!



    I installed the GD library just fine, and did a graceful restart of apache. Unfortunately, no dice for me. There are a slew of other things I would try, but I’m still treading lightly on best practices here at my work.. the site(s) I need to update the favicon for are sitting on RedHat Linux VMs in Azure. Due to the setup, I cannot just sftp put the favicon.ico where I need it.

    Workaround (for anyone else still having the issue, beyond following suggestions above):
    Install/activate “Very Simple Favicon Manager” by Guido. It has not been updated in a while, but I gave it a shot and it worked like a charm.

Viewing 15 replies - 1 through 15 (of 22 total)
  • The topic ‘There has been an error cropping your image’ is closed to new replies.