Results 1 to 8 of 8

Thread: Issue with back button

  1. #1
    Join Date
    Oct 2008
    Posts
    4

    Default Issue with back button

    Hi,

    We use webflow to manage an advanced search form. As the user can continually refine his queries, we only use one view. At each transition, the user is redirected to the same view displaying his current query and corresponding search results.

    Everything works fine when the user submit updated queries. But there is an issue when the user uses the back button.

    1) User goes to attributeSearch.htm, is redirected to attributeSearch.htm?execution=e1s1 and see content of page "e1s1"
    2) User fill in form and submit it
    3) User is redirected to attributeSearch.htm?execution=e1s2 and see content of page "e1s2"
    4) User modified the form and submit it
    5) User is redirected to attributeSearch.htm?execution=e1s3 and see content of page "e1s3"
    6) User pushes the browser back button
    7) URL is now attributeSearch.htm?execution=e1s2 but user sees content of page "e1s3" in place of content of page "e1s2"
    8) User pushes the browser back button
    9) URL is now attributeSearch.htm?execution=e1s1 but user sees content of page "e1s2" in place of content of page "e1s1"
    10) User can not use the back button anymore. No way go back to content of page "e1s1".

    What could be the reason of this issue?
    Or is it the normal behavior of weblfow?

    Thanks,
    Benoit

  2. #2
    Join Date
    Jun 2006
    Location
    The Netherlands
    Posts
    13,695

    Default

    It depends on your flow configuration and where you store your objects.
    Marten Deinum
    Java Consultant / Pragmatist / Open Source Enthousiast / Author


    Pro Spring MVC: With Web Flow
    Conspect

    Have you read the reference guide.
    Use the [ code ] tags, young padawan

  3. #3
    Join Date
    Oct 2008
    Posts
    4

    Default Config file

    Here is the flow definition. Do you need something else?
    Attached Files Attached Files

  4. #4
    Join Date
    Jun 2006
    Location
    The Netherlands
    Posts
    13,695

    Default

    Not sure if it is true what I see but it seems to me that you are storing all results in the sessionMap and a partial result in the searchForm. In the on-render there is no re-doing the search so basically it is displaying the old stuff that is in your session map.
    Marten Deinum
    Java Consultant / Pragmatist / Open Source Enthousiast / Author


    Pro Spring MVC: With Web Flow
    Conspect

    Have you read the reference guide.
    Use the [ code ] tags, young padawan

  5. #5
    Join Date
    Nov 2008
    Posts
    742

    Default

    Marten's right. The back button support is designed to work when you're storing your attributes in flow, view, and conversation scope, since these scopes are the only ones that get serialized when the snapshot is taken.

  6. #6
    Join Date
    Jun 2006
    Location
    The Netherlands
    Posts
    13,695

    Default

    Conversation is also taken outside of the snapshot. WIth flow/view you get UNDO behavior with conversation/session you get REDO behavior when back button is pressed.
    Marten Deinum
    Java Consultant / Pragmatist / Open Source Enthousiast / Author


    Pro Spring MVC: With Web Flow
    Conspect

    Have you read the reference guide.
    Use the [ code ] tags, young padawan

  7. #7
    Join Date
    Nov 2008
    Posts
    742

    Default

    Wait, is that right? I was under the impression that conversation scope was serialized with the snapshot too. Conversation-scoped attributes require serialization, after all...

    EDIT

    Ok, just reexamined this in the reference guide. You're right, they're in session. The serialization requirement is to support session replication.

    Was it always this way, or did conversationScope get serialized with the snapshot in previous SWF versions? If so, does anyone know which ones?

    Also, is there a way to enable conversationScope serialization/restoration with the snapshot?
    Last edited by InverseFalcon; Sep 3rd, 2009 at 03:35 PM.

  8. #8
    Join Date
    Jun 2006
    Location
    The Netherlands
    Posts
    13,695

    Default

    Was it always this way, or did conversationScope get serialized with the snapshot in previous SWF versions? If so, does anyone know which ones?
    It has always been this way, in SWF 1 also. I know this because I give/gave the course on webflow .

    Also, is there a way to enable conversationScope serialization/restoration with the snapshot?
    The only way would be to write your own snapshot mechanism which would mean a rewrite of a substantial part of webflow.
    Marten Deinum
    Java Consultant / Pragmatist / Open Source Enthousiast / Author


    Pro Spring MVC: With Web Flow
    Conspect

    Have you read the reference guide.
    Use the [ code ] tags, young padawan

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •