[STRUT][servlet]envoie d'info dynamique dans le <html:radio>
bonjour,
je souhaiterai récuperer la valeur du radio dans ma jsp mais ca marche pas
voici mon code
au niveau de la jsp
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
|
<form action="/ModuleWeb1/utilisateur" method="post">
<jsp:useBean id="listCamion" scope="request" class="testco.CamionBean" type="testco.CamionBean"/>
<center><table width="70%" border="1">
<tr>
<td><b><center>Selection</center></b></td>
<td><b><center>Nom du camion</center></b></td>
<td><center><input type="submit" value="CamionChoisi"></center></td>
</tr>
<logic:iterate id="idListCamion" name="listcamion" scope="request">
<tr>
<td width="11%"> <center>
<html:radio name="idListCamion" property="nomCamion" value="nomCamion"></html:radio>
</center></td>
<td width="30%"><bean:write name="idListCamion" property="nomCamion"/></td>
</tr>
</logic:iterate>
</table></center>
</form> |
et du coter de ma servlet
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14
|
public void doPost(HttpServletRequest request, HttpServletResponse response) throws
ServletException, IOException {
response.setContentType(CONTENT_TYPE);
PrintWriter out = response.getWriter();
String CamionChoisi= request.getParameter("CamionChoisi");
out.println("<html>");
out.println("<head><title>Utilisateur</title></head>");
out.println("<body bgcolor=\"#800080\">");
out.println("<h2>bou! ca marche</h2>\n");
out.println("</body>");
out.println("</html>");
out.close();
} |
lorsque je met un point d'arret sur le String CamionChoisi il est egal à "null"
Pourquoi ?