Wicket only knows how to construct bookmarkable pages when they have either a default constructor or a constructor taking *only* pageparameters. Any other constructor is outside the realm of wicket's capabilities and responsibility.
In your case, how could Wicket construct the page when it is directly navigated to without going through the form? That is bookmarkability. The only way is to add those extra parameters to the PageParameters object and use setResponsePage(MyPage.class, parameters) Martijn On Wed, Mar 9, 2011 at 5:09 AM, Alec Swan <[email protected]> wrote: > Hello, > > I have a form which calls the following statement in its onSubmit() method: > > setResponsePage(new MyPage(pageParameters, extraParam1, extraParam2)) > > NOTE: The MyPage construtor calls WebPage constructor as > super(pageParameters) and then adds extraParam1 and extraParam2 to > WebPage.getPageParameters() map. > > The end-result is that a user is redirected to a URL that has no parameters > in it, which means it cannot be bookmarked by the user. > > The goal is to have onSubmit() redirect the user to a page that has all > pageParameters encoded in the URL. > > What are we doing wrong and what is the recommended way to do this? > > Thanks > -- Become a Wicket expert, learn from the best: http://wicketinaction.com --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
