Ciao a tutti,
Sto creando un sistema di archiviazione (con dreamweaver)delle fatture ed ho la necessità di inserire all'interno della seguente TAB.:

id` int(11) NOT NULL AUTO_INCREMENT, `id_fornitore` int(11) NOT NULL, `documento_fiscale` varchar(255) DEFAULT NULL, `numero` int(11) DEFAULT NULL, `data_acquisizione` date DEFAULT NULL, `stato` varchar(255) DEFAULT NULL, `importo` int(11) DEFAULT NULL, `file` blob, PRIMARY KEY (`id`), KEY `id_fornitore` (`id_fornitore`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;

La fattura in formato cartaceo.

Ora, il form di inserimento è il seguente:

if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form3")) {
$insertSQL = sprintf("INSERT INTO fatture_registrate (id, id_fornitore, documento_fiscale, numero, data_acquisizione, stato, importo, `file`) VALUES (%s, %s, %s, %s, %s, %s, %s, %s)",
GetSQLValueString($_POST['id'], "int"),
GetSQLValueString($_POST['fornitore'], "int"),
GetSQLValueString($_POST['documento_fiscale'], "text"),
GetSQLValueString($_POST['numero'], "int"),
GetSQLValueString($_POST['data'], "date"),
GetSQLValueString($_POST['stato'], "text"),
GetSQLValueString($_POST['importo'], "int"),
GetSQLValueString($_FILES['file'], "text"));

mysql_select_db($database_XXX, $XXX);
$Result1 = mysql_query($insertSQL, $XXX) or die(mysql_error());

$insertGoTo = "index_fatture_registrate.php";

<form action="<?php echo $editFormAction; ?>" method="post" enctype="multipart/form-data" name="form3" class="tabella_nuovo_fattura2" id="form3">
<table align="center" class="testoa">
<tr valign="baseline">
<td align="right" nowrap="nowrap" bgcolor="#0000CC">Id:</td>
<td><input type="text" name="id" value="" size="32" /></td>
</tr>
<tr valign="baseline">
<td align="right" nowrap="nowrap" bgcolor="#0000CC">Id_fornitore:</td>
<td><select name="fornitore" id="fornitore">
<?php
do {
?>
<option value="<?php echo $row_fornitori['id_fornitore']?>"><?php echo $row_fornitori['cognome']?></option>
<?php
} while ($row_fornitori = mysql_fetch_assoc($fornitori));
$rows = mysql_num_rows($fornitori);
if($rows > 0) {
mysql_data_seek($fornitori, 0);
$row_fornitori = mysql_fetch_assoc($fornitori);
}
?>
</select></td>
</tr>
<tr valign="baseline">
<td align="right" nowrap="nowrap" bgcolor="#0000CC">Documento_fiscale:</td>
<td><select name="documento_fiscale" id="documento_fiscale">
<option value="." selected="selected">.</option>
<option value="Fattura">Fattura</option>
<option value="Ricevuta Fiscale ">Ricevuta Fiscale </option>
</select></td>
</tr>
<tr valign="baseline">
<td align="right" nowrap="nowrap" bgcolor="#0000CC">Numero:</td>
<td><input type="text" name="numero" value="" size="32" /></td>
</tr>
<td bgcolor="#0000CC">Data_rilascio:</td>
<td><link rel="stylesheet" href="../widget/calendario/jquery.ui.all.css">
<script src="../widget/calendario/jquery-1.8.2.js"></script>
<script src="../widget/calendario/jquery.ui.core.js"></script>
<script src="../widget/calendario/jquery.ui.widget.js"></script>
<script src="../widget/calendario/jquery.ui.datepicker.js"></script>
<link rel="stylesheet" href="../widget/calendario/demos.css">
<script>
$(function() {
$( "#datepicker" ).datepicker();
});
</script>
<input name="data" type="text" id="datepicker"></p>
<tr valign="baseline">
<td align="right" nowrap="nowrap" bgcolor="#0000CC">Stato:</td>
<td><select name="stato" id="stato">
<option value="." selected="selected">.</option>
<option value="Pagato">Pagato</option>
<option value="Sospeso">Sospeso</option>
<option value="Non Pagato">Non Pagato</option>
</select></td>
</tr>
<tr valign="baseline">
<td align="right" nowrap="nowrap" bgcolor="#0000CC">Importo:</td>
<td><input type="text" name="importo" value="" size="32" /></td>
</tr>
<tr valign="baseline">
<td align="right" nowrap="nowrap" bgcolor="#0000CC">File:</td>
<td><input type="file" name="file" id="file" /></td>
</tr>


Successivamente la visualizzazione del collegamento del file nella seguete Tabella dinamica:
<table border="0" cellpadding="5" cellspacing="2" class="tabella">
<tr bgcolor="#0000CC">
<td><span class="testoa">id</span></td>
<td><span class="testoa">documento_fiscale</span></td>
<td><span class="testoa">numero</span></td>
<td><span class="testoa">nome</span></td>
<td><span class="testoa">cognome</span></td>
<td><span class="testoa">ragione_sociale</span></td>
<td><span class="testoa">data_acquisizione</span></td>
<td><span class="testoa">stato</span></td>
<td><span class="testoa">importo</span></td>
<td><span class="testoa">file</span></td>
</tr>
<?php do { ?>
<tr>
<td>Modifica</td>
<td><?php echo $row_fatture_reg['documento_fiscale']; ?></td>
<td><?php echo $row_fatture_reg['numero']; ?></td>
<td><?php echo $row_fatture_reg['nome']; ?></td>
<td><?php echo $row_fatture_reg['cognome']; ?></td>
<td><?php echo $row_fatture_reg['ragione_sociale']; ?></td>
<td><?php echo $row_fatture_reg['data_acquisizione']; ?></td>
<td><?php echo $row_fatture_reg['stato']; ?></td>
<td><?php echo $row_fatture_reg['importo']; ?></td>
<td><?php echo $row_fatture_reg['file']; ?></td>
</tr>
<?php } while ($row_fatture_reg = mysql_fetch_assoc($fatture_reg)); ?>
</table>


HELP MEEEE!!!
NON HO LA PIU' PALLIDA IDEA DI COME SI FACCIA!!!