Dynamic generated file upload control<using javascript> doesn't post?
- by udaya
Hai
I am having a form which contains a filetype like this
on submit i am calling a script
function addRowToTable()
{
var tbl = document.getElementById('uploadTab');
var lastrow = tbl.rows.length;
var iteration = lastrow;
var row = tbl.insertRow(lastrow);
var cell2 = row.insertCell(0);
var e2 = document.createElement('input');
e2.type = 'file';
e2.name = 'ufile[]';
e2.id = 'ufile[]';
e2.size='50';
cell2.appendChild(e2);
}
This script generates The tr on a button click... In my view generatedsource tool i get the "" like this
<tr><td><input size="50" id="ufile[]" name="ufile[]" type="file"></td></tr>
when i submit the form i dont get the file name for the generated file type in my view page
But i get the file name foe the one that is default
What may be the problem?