What does this error on upload mean: "No uploaded files"?


for a few files with for websites untypical file extensions, I get the error message “No uploaded files” on uploading the file. No php error is logged. What does this error message mean? I found other users who face the same message, see here: https://github.com/getkirby/kirby/issues/1796#issuecomment-495367753. This message provides zero information to the end user.

Best Regards

There’s only one place where this error is thrown:

 if (empty($files) === true) {
            throw new Exception('No uploaded files');

in /kirby/cms/src/Api.php#614ff.

where $files is defined as

$files   = $this->requestFiles();

So the request doesn’t seem to contain any files.

This is some kind of a strange bug. I can reproduce it like this:

  1. upload several files, for example some *.dll files
  2. upload another file type, like some *.pak file
  3. delete all files and upload some different (third) file type
  4. upload again some type from first step.

The next upload will fail with this error message, although a file is selected and tried to be uploaded. After this error message, this is logged:

PHP Warning: POST Content-Length of 17889198 bytes exceeds the limit of 8388608 bytes in Unknown on line 0

Seems like there is some file extension filter side effect going on. Of course this is a very special, really unlikely real use case.

Im curious why your uploading .dll files. Is this a windows server? i think .pak files are sometimes used in games. Is this a big upload? Perhaps some software? You could try checking your php ini settings … perhaps your post_max_body and upload max file size settings are a bit low. (post_max_size should be slightly larger then the other setting, that isnt a typo)

upload_max_filesize = 20M
post_max_size = 21M

Hm, that is a post_max_size error, what is that value set to in your php.ini. Although the steps to reproduce are a bit strange.

Hi jimbobrjames,

yes, this is a local Windows 10 wampserver 3 set up. There is no real use case behind these uploads. I’m trying around with several things and so I upload random files from some directories of some apps.

I think the post size error is not related to the real problem here. The last file I’ve uploaded, when the error occurred, was some 1 kB file, so a very small file. Most likely it is a symptom of something else failing earlier as the steps before are not related to file size too.

The reason for asking about this error message via this thread was because I don’t understand the meaning of the message and I found zero documentation or posts about it. So I’m more interested in the ‘why’ this happens.

What happens if you try standard common files, like zips, pdfs, mp3s, word docs, spreadsheets?

I assume that this is some sort of server thing happening here resulting in an empty request. I don’t have any such files that would allow me to reproduce this (on a Mac).

I uploaded several Word and Excel documents, deleted them, added different files of these types and then uploaded a single 2 MB picture. The same error message occurred now. So it’s not related to the file type but maybe about the adding and removing of different types.

I’m doing this on FireFox. This time, no error was logged.

Well im thinking since your uploading files for software on a local windows, its perhaps possible that your anti virus / security software would interfere. Although its a server, you are using the the local file system that would be being watched by a security package like norton, mcaffee or eset… etc.

No virus/security software is triggered and Kirby 3 is the only software I have this issue with. In the past, I did tests of the same procedure (uploading random stuff to a web page or web app) and it was fine.

How likely is it that there are file name hashing conflicts/problems happen? I found out that the uploads are stored in the tmp directory of the webserver so maybe there is some conflict by chance which results in Kirby 3 misbehaving.

Personally, I have never seen this error, just trying to get it somehow by wildly trying to upload and delete files, but no chance.

Any upload is always stored in the tmp folder. That’s how uploads work. Since uploads always get a unique id, there shouldn’t be any conflicts, even if you upload the same file a hundred times.

Yep but afterwards they are moved/stored somewhere properly. So I mean if that pre-step already fails.

There is a specific file I can’t upload, regardless what I do. It is a 2 MB .jpg file from my smartphone camera. Other smartphone photos do work. I can see this 400 Bad Requesterror in my browsers console log:


(no clue what there’s wrong with this request, I don’t see anything suspicious but I’m no expert on this topic)

Could you maybe zip up the image and send it to us? Dont drop it into a post, it will get changed by the forum software. i know it hasnt worked for other kinds of files too, but you seem to be able reliably repeat it with this file

Yes, I’m able to reproduce it with this single file all time. I try to take a new photo with same issue. This specific file can’t be shared with public. Just give me a minute or two, I will be back quickly.

try opening it in a graphics program, and saving it again with a different file name. Maybe there is something slightly wrong with the file itself.

Something else you could try - since its a local server… try placing it in the right content folder manually in windows explorer and see if kirby is happy to work with it and display it in the panel from there. Im trying to work out if its a problem somewhere in the upload process or a bigger issue.

No zip allowed here. Try to download it from here: https://send.firefox.com/download/608f098a17489a48/#PgZ9zMkhs2m3xFk8hkv8vg

Password: kirby. File name wasn’t a problem. It must be about the meta data somehow.

It uploads totally fine for me, but im not on windows. Are you using the standard kirby setup or have yo u changed the default thumb driver to something else?

1 Like

Standard Kirby 3 setup with latest release, no changes regarding thumb driver.