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
| <?php
foreach($products as $cle => $product)
{
echo
'<CENTER>
<form action="index.php" method="POST">
<table>
<tr>
<td>
Produit
<br/>
<input type="text" style=width:40;height:20; name="id_product" value="'.$product['id_product'].'"</br>
<input type="text" name="nameProduct" value="'.$product['nameProduct'].'"</br>
</td>
<td rowspan="3">Description :</br><TEXTAREA name="description" rows=7 COLS=50>'.$product['description'].'</TEXTAREA></td>
</tr>
<tr>
<td>
Catégorie
<select name="categories">';
foreach($categories as $cle => $category){
if($product['id_category'] == $category['id'])
echo '<option value="'.$category['id'].'"selected>'.$category['name'].'</option>';
else
echo "<option value=".$category['id'].">".$category['name'].'</option>';
}
echo '</select>
</td>
</tr>
<tr>
<td>
URL Réécrite
<input type="text" style="width:194;height:20" name="link_rewrite" value="'.$product['link_rewrite'].'"</br>
</td>
</tr>
<tr>
<td>
Meta Mots-clés
<input type="text" style="width:194;height:20" name="meta_keywords" value="'.$product['meta_keywords'].'"
</td>
<td rowspan="3">
Description Courte
</br><TEXTAREA name="description_short" rows=7 COLS=50>'.$product['description_short'].'</TEXTAREA>
</td>
</tr>
<tr>
<td>Meta Description </br><TEXTAREA name="meta_description" rows=4 COLS=24>'.$product['meta_description'].'</TEXTAREA></td>
</tr>
<tr>
<td></td>
</tr>
</table>
<input type="submit" value="Modifier la base de données" />
</form>
</CENTER>
</br></br> ';
}
?> |
Partager