There is no need of setRedirect(true) anymore.
Wicket will see that the new page has different url than the current one and
will redirect automatically.


On Sat, Mar 19, 2011 at 2:09 PM, Vytautas <turi...@gmail.com> wrote:

> Hey guys,
>        simple question about page redirecting in wicket 1.5:
>
>        how should i implement such scenario:
>
>        @Override
>        protected void onInitialize() {
>                1. if (parameters are empty) {
>                2.      setResponsePage(page to redirect);
>                        //1.4 version: setRedirect(true);
>                        return;
>                }
>                3. get parameters and go further
>                super.onInitialize();
>        }
>
>        I would like to redirect to a correct page if parameters are not
> provided and do not proceed with markup for current panel/page
>        Currently it seems wicket tries to render panel.
>
>        Wicket version: 1.5-rc2
>
> Regards,
> Vytautas
> -----------------------------------
> www.xaloon.org
> www.allcarindex.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com <http://jweekend.com/>

Reply via email to