1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
| if($total) {
// debut du tableau
echo '<table bgcolor="#996523" align="center" border="0">'."\n";
// première ligne on affiche les titres prénom et surnom dans 2 colonnes
echo '<td bgcolor="#993333" width="127"><div align="center"><span class="Style1">NOM PRODUIT</td>';
echo '<td bgcolor="#993333" width="95"><div align="center"><span class="Style1">CDT DE COMMANDE</td>';
echo '<td bgcolor="#993333" width="95"><div align="center"><span class="Style1">UNITE DANS LE CDT</td>';
echo '<td bgcolor="#993333" width="115"><div align="center"><span class="Style1">PRIX </td>';
echo '<td bgcolor="#993333" width="115"><div align="center"><span class="Style1">CDT UNITAIRE</td>';
echo '<td bgcolor="#993333" width="110"><div align="center"><span class="Style1">PRIX CDT UNITAIRE UNITAIRE</td>';
echo '<td bgcolor="#993333" width="95"><div align="center"><span class="Style1">CATEGORIE</td>';
echo '<td bgcolor="#993333" width="95"><div align="center"><span class="Style1">LIVRAISON</td>';
echo '</tr>'."\n";
// lecture et affichage des résultats sur 2 colonnes, 1 résultat par ligne.
while($row = mysql_fetch_array($result)) {
echo '<td bgcolor="#CCCCCC"><div align="center"><name="nom_produit">'.$row["nom_produit"].'</td>';
echo '<td bgcolor="#CCCCCC"><div align="center"><name="cdt">'.$row["cdt"].'</td>';
echo '<td bgcolor="#CCCCCC"><div align="center"><input type="text" name="qt_cdt" size ="5" value="'.$row["qt_cdt"].'"</td>';
echo '<td bgcolor="#CCCCCC"><div align="center"><input type="text" name="prix" size ="5" value="'.$row["prix"].'"</td>';
echo '<td bgcolor="#CCCCCC"><div align="center"><name="u_qt_cdt">'.$row["u_qt_cdt"].'</td>';
echo '<td bgcolor="#CCCCCC"><div align="center"><name="prix_u_cdt">'.$row["prix_u_cdt"].'</td>';
echo '<td bgcolor="#CCCCCC"><div align="center"><name="categorie">'.$row["categorie"].'</td>';
echo '<td bgcolor="#CCCCCC"><div align="center">'.$row["-1"].'<input type="text" name="qt_recept" size="6"></td>';
echo '</tr>'."\n";
}
echo '</table>'."\n";
// fin du tableau. |
Partager