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 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85
| <?php
session_start();
$id = $_GET['id'];
require("configuration.php");
$result = mysql_query("SELECT $sbbproduit.id, $sbbproduit.hid, $sbbproduit.sid, $sbbproduit.libelle, $sbbproduit.ancienprix, $sbbproduit.spec, $sbbproduit.photoarticle, $sbbproduit.frais, $sbbproduit.promo, $sbbproduit.prix, $sbbproduit.visu, $sbbfrs.frsid, $sbbfrs.societe FROM $sbbproduit, $sbbfrs WHERE $sbbproduit.frsid= $sbbfrs.frsid AND $sbbproduit.id='$id'");
$row = mysql_fetch_row($result) or die('Erreur SQL !<br />'.$result.'<br />'.mysql_error());
?>
<title>En détail...</title>
<link href="style.css" type="text/css" rel="stylesheet" media="all">
</head>
<body>
<div align="center">
<div id="header"></div>
<div id="sommaire"></div>
<div id="corps">
<div id="colonne_centre">
<div id="txtcol_centre">
<table width="100%" border="0">
<tr><?php
if ($row[6] != "nul") {
$split = explode("../", $row[6]);
$row[6] = $split[1];
$img = "<img src=\"$row[6]\" width='120' height='120' target='blank'>";
$image2 = "<a href='$row[6]' target='blank'>Photo taille réelle</font></a><br>";
} else {
$img = "<img src=\"$images/na.jpg\" width=100 border=0>";
}
echo "<td colspan='2'>$img</a><br>$image2</td>";
?></tr>
<tr height="20">
<td valign="top" height="20"></td>
<td height="20"></td>
</tr>
<tr><?php
$libelle = $row[3];
?>
<td valign="top"><b>Article : </b></td>
<?php echo "<td>$libelle</font></td>"; ?></tr>
<tr>
<td valign="top"><b>Descriptif : </b></td>
<?
$descriptif = $row[5];
$descriptif = str_replace("[retour]","<br>",$descriptif);
$descriptif = str_replace("[gras]","<b>",$descriptif);
$descriptif = str_replace("[/gras]","</b>",$descriptif);
echo "<td>$descriptif</font></td>"; ?></tr>
<tr>
<td valign="top"><b>Prix net :</b></td>
<?
$price = $row[9];
$price = sprintf("%0.2f", $price);
echo "<td><font color=\"red\"><b>$price $devises</b></font></td>";
?></tr>
<?
$ancienprix = $row[4];
$ancienprix = sprintf("%0.2f", $ancienprix);?>
<tr>
<td valign="top">Prix public : </td>
<?php echo "<td>$ancienprix $devises</font></td>";
$gain = ($row[9] - $row[4]);
$gain = sprintf("%0.2f", $gain);
?></tr>
<tr>
<td valign="top"><b>Economie réalisée : </b></td>
<?php echo "<td><b>$gain $devises</b></font></td>"; ?></tr>
<?php
$fournisseur = $row[12];
?>
<tr><td valign="top"><b>Fournisseur : </b></td>
<?php echo "<td>
<b>$fournisseur</b></font></td>"; ?></tr>
</table>
// puis vient le formulaire |