Ok Update: At first I thought it was a component issue, and then I thought it was API but in fact it was neither.
My API is expecting to handle multiple files at one time requiring the filename attribute to be an array (or actually a string that acts as an array when rendered) not just a string.
Long story short.. too late.. the documentation for the jqxFileUpload could use a little help. Especially with the “multipleFilesUpload” defaulting to true, it’s a little confusing.
Example:
`<jqxFileUpload #fileUpload [fileInputName]=”‘uploadFiles'”>
</jqxFileUpload>`
Single file format from my PHP API:
array(1) {
["uploadFiles"]=>
array(5) {
["name"]=>
string(16) "testing.txt"
["type"]=>
string(10) "text/plain"
["tmp_name"]=>
string(14) "/tmp/phpmovWAm"
["error"]=>
int(0)
["size"]=>
int(153)
}
}
Example:
`<jqxFileUpload #fileUpload [fileInputName]=”‘uploadFiles[]'”>
</jqxFileUpload>`
Multiple file format from my PHP API:
array(1) {
["uploadFiles"]=>
array(5) {
["name"]=>
array(1) {
[0]=>
string(16) "testing.txt"
}
["type"]=>
array(1) {
[0]=>
string(15) "application/pdf"
}
["tmp_name"]=>
array(1) {
[0]=>
string(10) "text/plain"
}
["error"]=>
array(1) {
[0]=>
int(0)
}
["size"]=>
array(1) {
[0]=>
int(100194)
}
}
}
Seriously hope this helps someone else, cause it drove me crazy for a good day. 🙂
Happy coding!