On Tue, Apr 6, 2010 at 8:07 AM, McIlwee, Craig
<craig.mcil...@openroadsconsulting.com> wrote:
> As long as you prevent the browser from caching the page with the form (just 
> the page itself, caching the resources is fine) then when the user hits back 
> wicket will pull the old page instance from the pagemap and rerender it.  
> That page instance is the same one that was used the first time, so its state 
> will still be the same.  Just set some flag when the user submits, and also 
> check that flag when processing the form like this:
>

Not exactly.  How would Wicket know to pull the "old" page instance if
the browser is re-requesting a bookmarkable URL?  It wouldn't.  It
would just reconstruct the page from scratch.  In fact, Firefox
doesn't re-request anything from Wicket when you click the back button
(at least it doesn't in my app when IE does, go figure).  The way
Wicket keeps everything in synch is that each URL in your rendered
page (for forms, links, etc.) has information on it that "points" to a
specific page in the page map (that's what all the ?wicket:interface
stuff is).  So, when a form is submitted or a link (non-bookmarkable)
is clicked on your page, Wicket will load the specific page instance
from the page map and invoke the request on that.

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

Reply via email to