"Files" property with javascript not working in Firefox, even though it's per Mozilla docs

label Programming
account_circle Unassigned
schedule 3 Days
account_balance_wallet $5

I'm using this javascript code, per Mozilla docs, but it's not working in Mozilla, just in Chrome and Opera.

var data = new FormData(document.getElementById("uploadform"));		
var selected_file = document.getElementById('file').files[0];	
data.append('file-0', selected_file);
firefox also causes server error on the ajax file upload:
[Wed Jun 05 21:34:53 2013] [error] [client ::1] PHP Notice:  Undefined index: file-0 in /home/jeff/public/website.com/public/upload.php on line 11, referer: http://localhost/
I have no idea why the "files" property does not seem to be working on Firefox. Here's the relevant Mozilla docs page: Using FormData Objects.


Oct 20th, 2017

Thank you for the opportunity to help you with your question!

In most cases, the discipline is self-governed by the entities which require the programming, and sometimes very strict environments are defined

Please let me know if you need any clarification. I'm always happy to answer your questions.
Jun 14th, 2015

Studypool's Notebank makes it easy to buy and sell old notes, study guides, reviews, etc.
Click to visit
The Notebank
...
Oct 20th, 2017
...
Oct 20th, 2017
Oct 20th, 2017
check_circle
Mark as Final Answer
check_circle
Unmark as Final Answer
check_circle
Final Answer

Secure Information

Content will be erased after question is completed.

check_circle
Final Answer