Support » Plugin: Instant Images - One Click Unsplash Uploads » Cannot download image

  • Installed Plugin and tried to download an image – says cannot add image because
    “Unable to copy the image to the media library – please check your server permissions”

    You need to provide the steps / instructions of where to go to correct this. It is basic to your plugin. The solution should be upfront on your WP Plugin page

    What to do now?

Viewing 6 replies - 16 through 21 (of 21 total)
  • Plugin Author dcooney


    @ezweb What is the error message you are getting?

    The latest version of the plugin removed all cURL functions in favour of a simple PHP copy() method to download the images.



    Found the issue seems php allow_url_fopen needs to be on. Hope this helps someone 🙂

    Plugin Author dcooney


    thank you @ezweb



    @dcooney Why swap from using cURL? Doesn’t allow_url_fopen have many security implications? We had it flagged on a recent penetration test that highlighted that allow_url_fopen should be disabled.


    If anyone is struggling with this issue, try checking your PHP default_socket_timeout configuration! If it’s set to 0 or -1, change it to something above 30.

    I spent 4h trying to reset permissions, troubleshoot WP REST API etc. Nothing. It was driving me insane.

    Then tried swapping PHP version and it worked! At first, I thought I had something to do with PHP 7.3 compatibility. But then after comparing active extensions & PHP options, I narrowed it down to default_socket_timeout being set to 0. Changed it to 60 and it’s working perfectly on any PHP version.

    Jesus I wish this was listed somewhere as a requirement..


    Same issue…allow_url_fopen is enabled, default_socket_timeout is set to 60, uploads/instant-images permissions set to 755.

    Was there a fix?

    • This reply was modified 1 year, 6 months ago by ratputin.
Viewing 6 replies - 16 through 21 (of 21 total)
  • The topic ‘Cannot download image’ is closed to new replies.