将表单的form改为<html:form>.......</html:form>

解决方案 »

  1.   

    我找到一个方法可以
    pageContext.getServletContext().setAttribute
      

  2.   

    如果只是要传递一个String就用一个隐藏域。
    <html:hidden styleId="eventType" name="formName" property="taxpayer"/>
    递交页面时你用onSubmit事件:
    document.formName.taxpayer.value = "yourValue";
    document.formName.submit();
    就可以了。要是传递对象,就用session。
      

  3.   

    pageContext.getServletContext().setAttribute
    up
      

  4.   

    发现一个问题:
    pageContext.getServletContext().setAttribute
    中对象保存的空间是application
    而我希望是request