Hiren Dossani wrote: > hello, > > i am setting a session attribute in a jsp page. the location of this jsp page is in >webapps/base directory of the web server. > > i am not too sure if the same session attribute could be retrieved in a servlet >which is in another context. e.g. the servlet location is in > webapps/esab/WEB-INF/classes directory of the web server. > > thanks for all your help.
No, sessions are per application; servlets and JSPs in one app can not see the session data of another app (that would be a security risk). If you need to share session data between apps, you have to do so explicitly (e.g., store it in a database, file or EJB, that's available to both apps). Hans -- Hans Bergsten [EMAIL PROTECTED] Gefion Software http://www.gefionsoftware.com JavaServer Pages http://TheJSPBook.com =========================================================================== To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST". For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST". Some relevant FAQs on JSP/Servlets can be found at: http://archives.java.sun.com/jsp-interest.html http://java.sun.com/products/jsp/faq.html http://www.esperanto.org.nz/jsp/jspfaq.jsp http://www.jguru.com/faq/index.jsp http://www.jspinsider.com