Are there any reliable ways of disabling the Flash uploader and using the 'classic' uploader? Is this even possible without using an extension?

I'm just normally trying to upload an image via the admin - both /var and /media (and all sub-folders) are set to 777. The response I get back is:

{"error":"File was not uploaded.","errorcode":666}



This error comes from Varien_File_Uploader::__construct() in lib/Varien/File/Uploader.php

Here are the important parts


class Varien_File_Uploader
     * Uploaded file handle (copy of $_FILES[] element)
     * @var array
     * @access protected
    protected $_file;

    const TMP_NAME_EMPTY = 666;

    function __construct($fileId)
        if(!file_exists($this->_file['tmp_name'])) {
            $code = empty($this->_file['tmp_name']) ? self::TMP_NAME_EMPTY : 0;
            throw new Exception('File was not uploaded.', $code);
        } else {
            $this->_fileExists = true;

Looking back up the tree you see this is called

$uploader = new Mage_Core_Model_File_Uploader('image');

Which is extended from the Varien class, so the Varien_File_Uploader::_setUploadFileId($fileId) will construct the $this->_file array based on the key image, in this case.

So now the problem is why is $_FILES['image']['tmp_name'] empty?

I checked the 'error' field by temporarily replacing it with throw new Exception('File was not uploaded. ' . $this->_file['error'], $code);

I got 7, which is Failed to write file to disk. Introduced in PHP 5.1.0. which means it's a permissions issue.


Do a phpinfo() to check where your upload_tmp_dir is set to and make sure it's writable.

In my case, I was out of file space in the /tmp dir of my server.

| improve this answer | |

I've always used the No Flash Image Uploader, which worked with CE v1.4 - v1.7 without issue. The module is no longer available via Magento Connect, though its source code is actively maintained (as of Oct. 2016) and is available on GitHub.

You could grab the extension code and just extract the portion that you need if really necessary.

| improve this answer | |
  • That item MageBayVaporated and seems to no longer be available. – Fiasco Labs Feb 2 '16 at 18:43
  • I already installed. it's working well on product image upload, but in downloadable product file upload, it won't work. Do you have any other alternate solution for accomplishing without flash on downloadable product page downloadable section – senthil Feb 22 '18 at 16:35

I would say: "no". This is not possible out-of-the-box, but I found a plugin:


| improve this answer | |

I had the same, but I had an update of windows. Rebooted computer and everything worked again

| improve this answer | |

You can find here a Magento extension that allow multi-images upload using jquery and no flash : https://www.magentocommerce.com/magento-connect/multi-images-uploader-jquery-no-flash.html

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.