Reset context

Hi,

I have an JSF Portal application one of the Portlets displays some fields and link . The link opens a poup window where I can do some searchers and move the results to the parent window that all works OK the problem that I'm having is if the user closes the popup window using the browser X button then if I refresh the browser or go to the home page an select the portlet againg the data from the popup window is now showing in the Portlet instead of that portlet fields is there any way to clear the popup page context or anything so this doesn't happen

Thanks

[587 byte] By [chicoa] at [2007-11-26 17:08:44]
# 1
Are you using a session-scoped bean?
BalusCa at 2007-7-8 23:36:36 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2
Yes I'm
chicoa at 2007-7-8 23:36:36 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3
Sorry,The jsp for the poup for in in request mode in the configuration filethanks
chicoa at 2007-7-8 23:36:36 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 4

You can reset the session as follows:((HttpSession) FacesContext.getCurrentInstance().getExternalContext().getSession(true)).invalidate();

Let the bean detect if the page is referred by the portal and then pre-reset the session.

This might be a drastic solution. If you only want to reset the fields and not the whole session, then detect if the page is referred by the portal and then recreate the form object containing the fields:myForm = new MyForm();

BalusCa at 2007-7-8 23:36:36 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...