Hi,

I have trouble creating sessions when disabling cookie support in the browser.

Here is the problem.

I have a login component which contains a form.
The form listener contains the following code:
public void login(IRequestCycle cycle)
{
...
((HubPage) getPage()).getUserState().setUser(user);
final IPage page = cycle.getPage("OnlineUsers");
throw new PageRedirectException(page);
}

On the other hand I have a Register page with a form.
Here is the register form listener:
public void register(IRequestCycle cycle)
{
...
getUserState().setUser(user);
final IPage page = cycle.getPage("OnlineUsers");
throw new PageRedirectException(page);
}

In both cases we expect a session scoped UserState object to be created.

That what's happen. I can insert a userStateExists property in the OnlineUsers 
page and can verify that in both cases a userState object has been created.

If the client has cookies enabled, I can also see that in both cases a cookie 
is created to keep track of the session.

But when disabling cookies, while the login version adds a jsessionid to all 
urls, the register version doesn't and the session is then lost when following 
a link on the OnlineUsers page.

Any idea ?

Thanks.

Oscar

                
---------------------------------
Ring'em or ping'em. Make  PC-to-phone calls as low as 1ยข/min with Yahoo! 
Messenger with Voice.

Reply via email to