in che senso?
Io ho delle righe in un db, devo recuperare il nome dell'immagine associata a un id nel ciclo per poterla cancellare dalla directory.
Il form da cui parto è questo :
Codice PHP:
$risultato = mysql_query("Select * from news ORDER BY ID", $db);
//template tabella delle news
echo '<form action="delete.php" method="post" enctype="multipart/form-data">';
echo '<table width="100%"><tr><th width="5%">ID</th><th>News Italiano</th><th>News Inglese</th><th>Immagine</th><th width="5%">Modifica</th><th width="5%">Cancella</th></tr>';
while($riga = mysql_fetch_array($risultato)) {
echo '<tr>';
echo '<td>'.$riga['ID'].'</td>';
echo '<td>[b]'.$riga['titoloIt'].'[/b]</br>'.$riga['testoIt'].'</td>'; // news in italiano
echo '<td>[b]'.$riga['titoloEn'].'[/b]</br>'.$riga['testoEn'].'</td>'; // news in inglese
if ($riga['img']){echo "<td><a href=\"../img/upload/{$riga['img']}\" rel=\"shadowbox[Gallery]\"><img src=\"../img/upload/{$riga['img']}\" height=\"70px\"/></a></td>";} else {echo "<td>Nessuna Immagine</td>";}
echo '<td>[url="modify.php?ID='.$riga['ID'].'"]Modifica[/url]</td>';
echo '<td align="center"><input type="checkbox" name="ID[]" value="'.$riga['ID'].'" /></td>';
echo '</tr>';
}
echo '<tr><td></td><td></td><td></td><td></td><td></td><td><input type="submit" value="Cancella"></td></tr></table></form>';