j'ai fait une requête pour récupérer certains champs a partir d’un élément sélectionné dans un champ select:
Code : Tout sélectionner
$req="select * from table where table1.id in (select id from table2 where nom='$nom' and prenom='$prenom')";
$res=mysql_query($req);
echo $nom; ?><td width="251"><?php while ($row= mysql_fetch_assoc($res)) {
?>
<input type="text" name="chmap1" id ="chmap1" value="<?php echo $row['chmap1']; ?>" />
<?php } ?></td>
<td width="251"><?php while ($row= mysql_fetch_assoc($res)) {
?>
<input type="text" name="chmap2" id ="chmap2" value="<?php echo $row['chmap2']; ?>" />
<?php } ?></td>
mon souci c'est qu' il me récupère qu'un seul champ toujours, les autres non !Alors merci pour votre aide