Hmmm to jesli cie dobrze zrozumialem mozesz pokombinowac troche inaczej tak jak jest to w Netftpd2 nie kombinowac z Java ani Ajax'em a czystym js robic poprostu dynamiczne pola input za pomoca tablic czyli bede one wygladaly
I dzialalo by to tak gdy wypelnisz pierwszy input do zdarzenia onBlur="" mozesz dodac funkcje ktora bedzie szukac id tablicy ostatniego input'a i robily nastepny z id+1
<form name="UploadForm" id="UploadForm" method="post" enctype="multipart/form-data" action="/net2/index.php">
<a href="java script: document.UploadForm.state.value='browse'; document.UploadForm.state2.value='main'; document.UploadForm.submit();" title="Wstecz (accesskey

" accesskey="b"><img src="images/actions/crystal/back.png" alt="Wstecz (accesskey

" onMouseOver="this.style.margin='0px';this.style.width='34px';this.style.height='34px';" onMouseOut="this.style.margin='1px';this.style.width='32px';this.style.height='32px';" style="border: 0px; margin: 1px; width: 32px; height: 32px;" /></a>
  <a href="java script: createUploadWindow(); document.UploadForm.submit();" title="Wyślij (accesskey v)" accesskey="v"><img src="images/actions/crystal/button_ok.png" alt="Wyślij (accesskey v)" onMouseOver="this.style.margin='0px';this.style.width='34px';this.style.height='34px';" onMouseOut="this.style.margin='1px';this.style.width='32px';this.style.height='32px';" style="border: 0px; margin: 1px; width: 32px; height: 32px;" /></a>
<br /><br />
Wyślij do katalogu: <input type="text" class="longinput" name="directory" value="/www/cms" />
<a href="java script: createDirectoryTreeWindow('/www/cms', 'UploadForm.directory');" title="Lista" ><img src="images/actions/crystal/view_tree.png" alt="Lista" onMouseOver="this.style.margin='0px';this.style.width='34px';this.style.height='34px';" onMouseOut="this.style.margin='1px';this.style.width='32px';this.style.height='32px';" style="border: 0px; margin: 1px; width: 32px; height: 32px;" /></a>
<br /><br />
<input type="hidden" name="net2ftp_ftpserver" value="szu.pl" />
<input type="hidden" name="net2ftp_ftpserverport" value="21" />
<input type="hidden" name="net2ftp_username" value="marcio@szu.pl" />
<input type="hidden" name="net2ftp_password_encrypted" value="7903CE1C2DF0990DF40E0E" />
<input type="hidden" name="net2ftp_language" value="pl" />
<input type="hidden" name="net2ftp_skin" value="1" />
<input type="hidden" name="net2ftp_ftpmode" value="automatic" />
<input type="hidden" name="net2ftp_passivemode" value="" />
<input type="hidden" name="net2ftp_sslconnect" value="" />
<input type="hidden" name="net2ftp_viewmode" value="" />
<input type="hidden" name="net2ftp_sort" value="" />
<input type="hidden" name="net2ftp_sortorder" value="" />
<input type="hidden" name="state" value="manage" />
<input type="hidden" name="state2" value="uploadfile" />
<input type="hidden" name="formresult" value="result" />
<input type="hidden" name="max_file_size" value="50000000" />
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td valign="top" width="50%">
<div class="header31">Pliki</div><div style="font-size: 80%;">Wpisane tu pliki będą wysłane na serwer FTP.</div><br />
</td>
<td valign="top" width="50%">
<div class="header31">Archiwa (zip, tar, tgz, gz)</div><div style="font-size: 80%;">Wpisane tu archiwa będą wysłąne na serwer FTP.</div><br />
</td>
</tr>
<tr>
<td valign="top" width="50%">
<input type="file" class="uploadinputbutton" maxsize="50000000" name="file[]" onChange="add_file('file', 1);" /><br><span id="file_1"><input type="button" value="Dodaj następne" onClick="add_file('file', 1);" /></span><br />
</td>
<td valign="top" width="50%">
<input type="file" class="uploadinputbutton" maxsize="50000000" name="archive[]" onChange="add_file('archive', 1);" /><br><span id="archive_1"><input type="button" value="Dodaj następne" onClick="add_file('archive', 1);" /></span>
<br /><div style="font-size: 80%;"><input type="checkbox" name="use_folder_names" value="yes" checked/> Użyj nazw katalogów (automatycznie tworzy podkatalogi)</div><br />
</td>
</tr>
</table>
</form>
Mam nadzieje ze to ci pomoze zrozumiec o co mi chodzi, Patrz na funkcje js i pogrubiony Kod.