就用方法一可以了!
javabeanID.request.getParameter()

解决方案 »

  1.   


    对arfeng75:
    你那个是在struts架构下吧?
      

  2.   

    比较懒的方法:在提交时把想要的参数加到form的action属性中,比如<script>
    function onFormSubmit(form)
    {
        this.action += "&test=" + this.test.value;
        this.action += "&anotherElement=" + this.anotherElement.value;
    }
    </script>
    <form method="post" onSubmit="onFormSubmit(this)" action="index.jsp?1=1">
    <input type="text" name="test">
    </form>其他方案是用第三方组件如struts, jspsmartupload 或者...... 自己解析-_-!
      

  3.   

    方法一要对参数进行编码(包括中文和特殊字符),还不能有太多数据
    方法二是错的,你不可能将两个表单同时提交到一个url
    正确的方法是cm4ever说的,用apache的commons-upload或jspsmartupload