• Resolved xhark

    (@xhark)


    Hello,

    when I try to add image to an article, I’ve an error :
    Failed to write file to disk

    I’ve found in wp-admin/includes/file.php :

    $upload_error_strings = array( false,
    		__( "The uploaded file exceeds the <code>upload_max_filesize</code> directive in <code>php.ini</code>." ),
    		__( "The uploaded file exceeds the <em>MAX_FILE_SIZE</em> directive that was specified in the HTML form." ),
    		__( "The uploaded file was only partially uploaded." ),
    		__( "No file was uploaded." ),
    		__( "Missing a temporary folder." ),
    		__( "Failed to write file to disk." ));

    but I don’t understand why this error appears.

    All directory “wp-content/upload” and subdirectory/files are chmod 777 and owner is good.

    php function restriction ? any idea ?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter xhark

    (@xhark)

    I’ve found the issue :

    change in php.ini :
    upload_tmp_dir=”/tmp”

    it’s a bug in php5, fixed since PHP 5.2.1

    more info : https://bugs.php.net/bug.php?id=39123

    Which version of wordpress are you running? I am having the same problem but don’t seem to be able to find the php.ini file in wp-content/upload or a file.php in the includes folder =S

    I am running V2.6.2.

    Do you have any ideas what might be wrong?

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Image upload : Failed to write file to disk’ is closed to new replies.