Hi,

the setresponsepage only marks, that the pagetarget is something else on
the end of the cycle, but it isn't stopping the execution of the current
page. If you want that, then use:
throw new RestartResponseException(getApplication().getHomePage());

Regards,
Peter

2010-02-04 14:16 keltezéssel, Martin Asenov írta:
> Hello guys!
> 
> I've got three pages, where I do certain check in the beginning and if the 
> criteria is not met, I redirect to home page. I make it that way:
> 
> public MyPageClass {
> 
>             if (something) {
>                         system.out.println("mypageclass - we're in");
>                         setResponsePage(getApplication().getHomePage());
>             }
> 
> .... page initialization afterwards
> }
> 
> The strange thing is that it works for one of the pages, for another two - it 
> does not - there is no redirection at all; it goes on with further 
> initializing. The criteria check block is the very same one in each of the 
> pages.
> 
> Appreciate if someone helps!
> 
> Regards,
> Martin

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to