Hi,

In my application we also had similar needs and here is how we solved it.
When an Ajax event is handled we also update the URL's hash with all
necessary information to redo the same event
(target.appendJavaScript('updateHash("someValue")')).
When back button is clicked
http://tkyk.github.com/jquery-history-plugin/ notifies us and gives us
the hash of the previous state. Then we send the hash value to the
server side (a special AjaxHistoryBehavior is added to each page) and
#onAjaxBackButton() sends a Wicket 1.5 event with payload the hash
value + the AjaxRequestTarget to the behavior's component (the page)
which broadcasts it to all components inside it and they decide
whether they need to update themselves depending on the hash value.
So it is not exactly "going back". It is more "move to a state".

HTH

On Thu, Nov 3, 2011 at 10:25 AM, Dirk Arnoldt <[email protected]> wrote:
> there are two reasons:
>
> 1) our wicket 1.5 application makes heavy use of AJAX e.g. switching
> panels. As far as I know the wicket back button support has problems with
> AJAX - the DOM modifications are not reflected correctly (see
> https://issues.apache.org/jira/browse/WICKET-271)
>
> 2) our application has workflows and we must ensure that these stay
> consistent such as billing events are not triggered twice.
>
> Dirk
>
>
>> since wicket provides backbutton support why are you fighting it?
>>
>> -igor
>>
>> On Fri, Oct 28, 2011 at 2:22 AM, Dirk Arnoldt <[email protected]>
>> wrote:
>>> Hi,
>>>
>>> I'm facing a problem with multi tabbed browsing.
>>>
>>> In a wicket application I currently detect browser navigation (back
>>> button)
>>> by means of timestamps. As a result I display a warning to the user
>>> telling
>>> him that he should not use the back button and subsequently forward him
>>> to
>>> the next page in the browser history.
>>>
>>> This works for me as long as the user doesn't use multiple browser tabs
>>> or
>>> windows. Is there a way to determine which pages belongs to the same
>>> browser
>>> tab/window?
>>>
>>> Another problem with my current solution is, that the user can jump
>>> between
>>> arbitray pages in browser history. I want to redirect the user to the
>>> latest
>>> page from my application - which must not be the newest page in browser
>>> history. Is there a way to determine the latest page in a wicket
>>> session?
>>>
>>> Thanks
>>> Dirk
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: [email protected]
>>> For additional commands, e-mail: [email protected]
>>>
>>>
>>
>>
>
>
> --
> Dirk Arnoldt   Senior Software Engineer
> Tel: +49 721 96448-0   Fax: +49 721 96448-286   [email protected]
> fun communications GmbH   Lorenzstraße 29   D-76135 Karlsruhe
> Geschäftsführer Johannes Feulner
> Amtsgericht Mannheim HRB 106906   www.fun.de
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>



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

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to