I am trying to emulate the multiple upload files in html form that looks similar to Yahoo's email attachments steps. I have this code as my html form. (outdata is a NSMutableString.)
id out = @"<form action=\"\" method=\"post\" enctype=\"multipart/form-data\" name=\"form1\" id=\"form1\">"
"<label>upload file:"
"<p>"
"</label>"
"<label>"
"<input type=\"file\" name=\"file1\" id=\"file1\" value=\"LookUp1\" />"
"</label>"
//"<label>"
//"<input type=\"submit\" name=\"button\" id=\"button\" value=\"Submit1\" />"
//"</label>"]
//"</form>"
//add 2nd browse submit
//"<form action=\"\" method=\"post\" enctype=\"multipart/form-data\" name=\"form1\" id=\"form1\">"
//"<label>upload file"
//"</label>"
"<p>"
"<label>"
"<input type=\"file\" name=\"file2\" id=\"file2\" value=\"LookUp2\" />"
"</label>"
"<label>"
"<input type=\"submit\" name=\"button\" id=\"button\" value=\"Submit\" />"
"</label>"
"</form>";
[outdata appendString:out];
The result of the html output is below. Basically, the server will save the file on the server hard drive. It worked fine. Except that it only saved the file the first Browse... button not the 2nd one even though I populated both boxes. The goal is that when I clicked on the Submit button, the files in both boxes should be posted one after another.
Is this client side javascript I need to write. Any help would be appreciated.
