<th colspan="1" class="a-center"><span class="nobr">Prix unitaire</span></th> <th class="a-center" rowspan="1">Quantité</th> <th colspan="1" class="a-center">Sous-total</th> <th class="a-center" rowspan="1">Supprimer</th> </tr> </thead> <tfoot> <tr class="first last"> <td class="a-center last" colspan="50"><button class="button btn-continue" title="Continue Shopping" type="button"><span><span>Continuer vos achats</span></span></button> <button id="update_cart_button" class="button btn-update" title="Update Shopping Cart" value="update_qty" name="update_cart_action" type="submit"><span><span>Mettre à jour le panier</span></span></button> <button id="empty_cart_button" class="button btn-empty" title="Clear Shopping Cart" value="empty_cart" name="update_cart_action" type="submit"><span><span>Vider le panier</span></span></button></td> </tr> </tfoot> <tbody> <?php $products = $panier->getProducts(); $total = 0; foreach ($products as $product) { if ($product['promotion'] != 0) { $prix = $product['prix'] * (100 - $product['promotion']) / 100; } else { $prix = $product['prix']; } echo ' <tr class="odd produit" id-produit=' . $product['id_produit'] . '> <td><a class="product-image" href="product.php?idProduit=' . $product['id_produit'] . '"><center><div class="image_gallery" style="width:110px;height:75px;line-height:75px;overflow:hidden;"><center><img style="vertical-align : middle;" src="media/' . $product['nom_photo'] . '.jpg" alt="product"></div></a></td> <td><h2 class="product-name"> <a href="product.php?idProduit=' . $product['id_produit'] . '">' . $product['libelle_produit'] . '</a> </h2></td> <td class="a-center"><span class="cart-price"> <span class="price">' . number_format($prix, 2, ',', ' ') . '€</span> </span></td> <td class="a-center"><input maxlength="12" class="input-text qty" title="Qty" size="4" value="' . $_SESSION['panier'][$product['id_produit']] . '" name="cart[1][qty]"></td> <td class="a-center"><span class="cart-price"> <span class="price">' . number_format($_SESSION['panier'][$product['id_produit']] * $prix, 2, ',', ' ') . '€</span> </span></td> <td class="a-center last"><div id="delete_product_button" style="cursor:pointer;width:30px;margin:auto;" id-produit="' . $product['id_produit'] . '" class="btn-remove btn-remove2" title="Supprimer" href="shoping-cart.php?action=delete&idProduit=' . $product['id_produit'] . '">x</div></td>