Missing a temporary folder

WordPress is giving the error on image upload: "image.jpg" has failed to upload due to an error "Missing a temporary folder."

If you are receiving this error please follow these simple instructions below:

  1.  Create a "tmp" folder in your WordPress root directory with 777 permissions. You can even use FTP Client or FIle Manager of cpanel.
  2.  Also, create a "php.ini" file in the same location.
  3.  Add the following in php.ini file:

    upload_max_filesize = 16M
    upload_tmp_dir = on
    upload_tmp_dir = /home/username/public_html/wordpressDir/tmp

    Please make sure to replace username with your hosting username, and wordpressDir with the directory name of your WordPress install. 
    If you have installed WordPress on your homepage then the path will be like: upload_tmp_dir = /home/username/public_html/tmp

  4.  Copy the same php.ini file to your wp_admin folder.


=======================================================

otherwise, you can also try this.

add below lines to wp-config file for your domain.

===
define('WP_TEMP_DIR',ABSPATH.'wp-content/uploads/');
===


  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Move Wordpress From Another Server

You can use WordPress Migrations Plugins available in cPanel to move WordPress from one server to...

How to ADDon the domain and install wordpress on it?

How to ADD the ADDON  domain:   1: Login to your cpanel.   2: There  under the section of "...

Getting issue "While Publishing" post in Wordpress site?

To solve the issue related to Failure in updating any Post in Wordpress please follow the below...

How to solve HTTP 500 Error on website?

To solve the HTTP 500 Error please follow the below steps:   1: This issue you will face when...

How to upgrade the Wordpress version?

To upgrade the Wordpress version please follow the below steps:   1: If you want to upgrade the...