It seems the filename is automatically added (just tested in Chrome and not sure if this differs in other circumstances).
Steps To Reproduce
- Go to http://jsfiddle.net/rwone/vsRSf/
- Open Network tab in Developer Tools
- Select two images and click the button
- View the Network tab and you will see the filenames are defined
The image information is only defined with two parameters, and not the third filename parameter:
myFormData.append(name, file);
Original fiddle based on this post: