0 Replies Latest reply on Feb 6, 2007 2:26 PM by J.R. Ector

    MockHttpSession

    J.R. Ector Newbie

      I'm using Seam 1.1GA with ICEFaces 1.5.2 and I'm trying to store a string in my HTTPSession.
      Can someone tell me the steps I need to store a variable in the session and later retrieve it ? I've tried storing it using:

      ServletContext context = new MockServletContext();
      HttpSession session = new MockHttpSession(context);
      session.setAttribute("user", user);
      


      And tried retrieving it with:

      ServletContext context = new MockServletContext();
      HttpSession session = new MockHttpSession(context);
      User stored = (User) session.getAttribute("user");
      


      But, when I go to get it it's null.

      Any help would be appreciated.

      JR