We have ContextListener implemented ( i.e. our class implements javax.servlet.ServletContextListener)
Am trying to obtain the user id and I have ServletContextEvent object available as parameter for contextInitialized
Right now it is hardcoded.
The same username is obtained in JSP like this
<jstl:set var="userId" scope="session" value="<%= request.getRemoteUser() %>"></jstl:set>
Is there anyway, I obtain the same from JSP, as I need the value that is being set there
Obtain the username in the file carsContextListener.java
What is hardcoded ? Which user ? Please show us that code.
public void contextInitialized(Servlet
String fileSeperator = System.getProperty("file.s
//FIXME: the user is hardcoded, need to get an actual session attrib