请大家帮忙看下这里是什么原因,谢谢!Action-->jsp过程Action中用下面的方法:      ServletActionContext.getRequest().setAttribute("user", user); jsp中
      ${requestScope.user.name}
      ${sessionScope.user.name}
      ${applicationScope.user.name}
     
       上面三种都得不到值 (不明白这里为什么得不到值)---------------------------------------------------------------------------Action中用下面的方法把user放在作用域中:      ServletActionContext.getServletContext().setAttribute("user", user);jsp中:
      ${applicationScope.user.name}可以得到值

解决方案 »

  1.   

    看看你的Action跳转是不是弄成redirect的了。
      

  2.   

    getRequest()
      看看你跳转界面是怎么跳的,,是转发和还是重定向..request,response
    保存的作用域自然就不同了..
      application是全局的,任何情况就可以.
      

  3.   

    在页面测试一下:
    <%
      User user = request.getAttribute("user");
      System.out.println(user.name);%>看看你的ruquest中是否有值,如果有值,使用${user.name}试试!
      

  4.   

    谢谢大家,现在可以了,,我先前就是把 type弄成redirect了,改成默认的就可以了