Skip to Content
0
Former Member
Mar 27, 2007 at 01:49 PM

JSP Dynpage iView 'Open in New Window' losses session data

33 Views

Hi All,

I have a JSP Dynpage that displays some position holder information based on a position id passed in by the URL query string. The problem that I am trying to solve is to allow the user to open the iView in its own window by using the 'Open in New Window' option from the button in the upper right of the iView title bar. When this happens the URL query string is no longer available so the iView has problems. My solution is to store the position id in the session object then read from that session object when the query string is not available - when opening in a new window.

But what is happening is that the position id saved in the session object is no longer there when the new window opens. I have looked else where on this site but all posts seem to deal with data transfer from JSP Dynpage to the JSP page. This issue is dealing with a page getting re-opened in a new page (browswer).

I can't seem to get the session object to work between JSP Dynpages at all, I would think that the data put into the session would stay there untill either cleared or the session ends. Am I missing some configuration settings? I have included some of the key code below.

// GET THE POSITION ID FROM THE URL QUERY STRING

String PosId;

PosId = request.getParameter("CKey");

if (PosId == null)

{

myBean.testing = (String) request.getComponentSession().getValue("PosId");

}

else

{

PosId = PosId.substring(6, 14);

request.getComponentSession().putValue("PosId", PosId);

myBean.testing = "POSID:" + PosId;

}

Thanks for all ideas and help.

Don