Php help

trix.power Messages postés 7 Statut Membre -  
 trixpower -
Bonjour,
salut tous le monde
j'ai un problème pour développer un questionnaire utilisant les bouton radio et php
j'ai déjà préparer ma page le question et le bouton pour chaque question
mais lorsque je sélectionne un bouton pour chaque question ça ne marche pas
bon dans toutes la liste des question il sélectionne un seul bouton radio tant que j'aime que chaque question soit répondu par un bouton
voila le code
<table border="0" bordercolor="#000099">
<tr>
<td rowspan="2"> <div align="center"><strong>Facteur économique
et sociaux</strong></div></td>
<td colspan="5"> <div align="center"><strong>Degré d'importance</strong></div></td>
<td rowspan="2"> <div align="center"><strong>Commentaire</strong></div></td>
</tr>
<tr>
<td><div align="center"><strong>1</strong></div></td>
<td><div align="center"><strong>2</strong></div></td>
<td><div align="center"><strong>3</strong></div></td>
<td><div align="center"><strong>4</strong></div></td>
<td><div align="center"><strong>5</strong></div></td>
</tr>
<tr></tr>
<td bgcolor="#E0E0E0">La stabilité économique et politique.<br></td>
<td colspan="5" bgcolor="#E0E0E0">
<input type="radio" name="radiobutton" value="radiobutton">
<input type="radio" name="radiobutton" value="radiobutton"> <input type="radio" name="radiobutton" value="radiobutton">
<input type="radio" name="radiobutton" value="radiobutton"> <input type="radio" name="radiobutton" value="radiobutton">
</td>
<td rowspan="10"><textarea name="textarea" rows="12"></textarea></td>
</tr>
<tr>
<td>La taille et le dynamisme de marché local.</td>
<td colspan="5">
<input type="radio" name="radiobutton" value="radiobutton">
<input type="radio" name="radiobutton" value="radiobutton"> <input type="radio" name="radiobutton" value="radiobutton">
<input type="radio" name="radiobutton" value="radiobutton"> <input type="radio" name="radiobutton" value="radiobutton"></td>
</tr>
<tr>
<td bgcolor="#E0E0E0">Le degré d’ouverture du marché
et d’intégration régionale. <br> </td>
<td colspan="5" bgcolor="#E0E0E0"> <input type="radio" name="radiobutton" value="radiobutton">
<input type="radio" name="radiobutton" value="radiobutton"> <input type="radio" name="radiobutton" value="radiobutton">
<input type="radio" name="radiobutton" value="radiobutton"> <input type="radio" name="radiobutton" value="radiobutton"></td>
</tr>
<tr>
<td>Le niveau d’investissement intérieur.<br> </td>
<td colspan="5"><input type="radio" name="radiobutton" value="radiobutton">
<input type="radio" name="radiobutton" value="radiobutton"> <input type="radio" name="radiobutton" value="radiobutton">
<input type="radio" name="radiobutton" value="radiobutton"> <input type="radio" name="radiobutton" value="radiobutton"></td>
</tr>
<tr>
<td bgcolor="#E0E0E0">L’existence des aides pour l’investissement.<br>
</td>
<td colspan="5" bgcolor="#E0E0E0"> <input type="radio" name="radiobutton" value="radiobutton">
<input type="radio" name="radiobutton" value="radiobutton"> <input type="radio" name="radiobutton" value="radiobutton">
<input type="radio" name="radiobutton" value="radiobutton"> <input type="radio" name="radiobutton" value="radiobutton"></td>
</tr>
</table>..
comment puis je faire SVP
et merci a tous
A voir également:

2 réponses

vincent170186 Messages postés 329 Statut Membre 52
 
salut !
tout tes radio button on le meme attribut de nom ! c'est donc normal que tu ne puisse en choisir qu'un sur la liste si tu veux pouvoir les cocher independament les uns des autre remplace le type='radio' par type='checkbox'et un conseil donne leur un nom different a chaque ! (sinon tu auras du mal a recupéré tes données !)
voila !
0
drakith
 
met des nom différents a ter bouton par question et des valeur différents par réponses

exemple:
<td bgcolor="#E0E0E0">La stabilité économique et politique.<br></td> 
<td colspan="5" bgcolor="#E0E0E0"> 
<input type="radio" name="q1" value="1"> 
<input type="radio" name="q1" value="2"> 
<input type="radio" name="q1" value="3"> 
<input type="radio" name="q1" value="4"> 
<input type="radio" name="q1" value="5"> 
</td> 
<td rowspan="10"><textarea name="textarea" rows="12"></textarea></td> 
</tr> 
<tr> 
<td>La taille et le dynamisme de marché local.</td> 
<td colspan="5"> 
<input type="radio" name="q2" value="1"> 
<input type="radio" name="q2" value="2"> 
<input type="radio" name="q2" value="3"> 
<input type="radio" name="q2" value="4"> 
<input type="radio" name="q2" value="5"> </td> 
</tr> 


0
trixpower
 
grand merci pour votre aide
0