listbox en php ??? [php] - PHP - Programmation
Marsh Posté le 13-12-2002 à 16:36:09
echo "<select name="liste"> 
<option value="Choix 1">Choix 1 
<option value="Choix 2">Choix 2  
<option value="Choix 3">Choix 3  
</select>"; 
  Et oublie pas de fermer tes balises <option>, hein.
 Et oublie pas de fermer tes balises <option>, hein.
Marsh Posté le 13-12-2002 à 16:40:04
petite correction : 
 
echo "<select name=\"liste\"> 
<option value=\"Choix 1\">Choix 1 
<option value=\"Choix 2\">Choix 2   
<option value=\"Choix 3\">Choix 3   
</select>"; 
 
ou : 
 
echo "<select name='liste'> 
<option value='Choix 1'>Choix 1 
<option value='Choix 2'>Choix 2   
<option value='Choix 3'>Choix 3   
</select>";
Marsh Posté le 13-12-2002 à 17:06:51
ou 
 
echo '<select name="liste"> 
<option value="Choix 1">Choix 1 
<option value="Choix 2">Choix 2   
<option value="Choix 3">Choix 3   
</select>'; 
Marsh Posté le 13-12-2002 à 17:20:14
personne ne ^peut m ecrire cette fonction ca fait 2 jours que je suis dessus et ca marche po et ca me soule grave ![[:toad666] [:toad666]](https://forum-images.hardware.fr/images/perso/toad666.gif) 
 
Marsh Posté le 13-12-2002 à 17:33:03
| sakuraba a écrit : personne ne ^peut m ecrire cette fonction ca fait 2 jours que je suis dessus et ca marche po et ca me soule grave  | 
Lit donc le message de beleg Posté le 12-12-2002 à 13:22:18 sur ton autre discution. 
 
Il te fait ce que tu demandes après a toi de t'en servir.
Marsh Posté le 13-12-2002 à 17:40:35
| sakuraba a écrit : je comprend pas ce qu il faut faire   | 
Ben tu copie cole cette fonction dans ton code à toi et pour l'utiliser, tu fais comme avec n'importe quelle fonction.  
 
Marsh Posté le 13-12-2002 à 16:34:31
<select name="liste">
<option value="Choix 1">Choix 1
<option value="Choix 2">Choix 2
<option value="Choix 3">Choix 3
</select>
comment ecrire ca en php