request.getParameters() <- 少了一个 s .

解决方案 »

  1.   

    faint,不是说明类型不兼容了吗,你把一个String 型付给一个String 数组当然不行了.
    试试request.getParameterValues()
      

  2.   

    sorry, 刚才打错了。
     是 request.getParameterValues() . 返回的是 String[] 型
      

  3.   

    我在开发一个<input type=Checkbox name=chebox value="+keyID+">的东西
    为了让提交页面能够认识到谁被选中,谁没有被选中,我就做上如下的处理:
    jsp1:<%
        for(int i = 0; i < n; i++)
        {
    %>
    <input type="checkbox" name=”chebox” value="XX">//名称相同,value不同
    <%
        }
    %>
    jsp2:<%
        String[] chebox = request.getParameter("chebox");//处理value
    %>谢谢你们上边的提示
    但我在我的程序中,如下所做:
        String[] chebox=request.getParameterValues("chebox");
        for (int i=0; i<chebox.length;i++) 
         out.println(chebox[i]);
    狗屁信息都没打印出来,请问我该如何做呀!!!
      

  4.   

    name=”chebox” 
    这个引号错了,应该是name="chebox"