如题

解决方案 »

  1.   

    郁闷了
    如果我不用<html:form>直接用<form>没点问题
      

  2.   

    struts标签里写<%=%>是会有问题的,比如:<html:link page="<%=url%>"></html:link>
    我也遇到过,而且遇到不止一次了,我觉得应该是解析顺序的问题,可能是struts标签先解析吧!这种问题可以用EL表达式解决!比如可以这样写:
    <%
      String url="";
      request.setAttribute("url",url);
    %>
    <html:link page="${url}"></html:link>
      

  3.   

    struts <html:form/>标签属性action定义如下:
    <name>action</name>
      <required>true</required>
      <rtexprvalue>true</rtexprvalue>
    </attribute>
    其中<rtexprvalue>true</rtexprvalue>这句设为true表明这个属性值可以用表达式获得,所以用<%= %>没有问题,用${}要方便些。
      

  4.   

    难道不能用普通标签吗?非用struts标签
    <form name="" method="post" action=<%=%>>
    这不很好吗?
      

  5.   

    有区别,特别是你的action值是struts的action。
      

  6.   

    我的用的是action="<%=request.getContextPath()%>/login.do"
    是不是action的值只能有<%  %>啊
      

  7.   

    struts标签中用<%=%>,取出的是null值.
    用表达式唯一的解