Wicket
  1. Wicket
  2. WICKET-4488

URL with a previous page version ignores requested page based on mount path

    Details

      Description

      See discussion on http://mail-archives.apache.org/mod_mbox/wicket-users/201203.mbox/browser

      With 2 mounts /page1 and /page2 to stateful pages and the following sequence:
      1-With a new session, user visits "/page1". Displayed URL is "/page1?0"
      2-Whatever, without expiring session
      3-User requests URL "/page2?0" because it was bookmarked, received via email, etc.
      4-Rendered page is "/page1?0" which was stored in the page map. The actual URL displayed is "/wicket/bookmarkable/com.mycompany.Page1?0"

      If a requested page id exists but does not match the page class mounted on the actual requested url, Wicket should not use the old page version. This is very counter-intuitive for users having bookmarks to stateful pages or exchanging links.

      1. pageVersions.zip
        24 kB
        Bertrand Guay-Paquet

        Issue Links

          Activity

          Hide
          Bertrand Guay-Paquet added a comment -

          Quickstart

          Show
          Bertrand Guay-Paquet added a comment - Quickstart
          Hide
          Martin Grigorov added a comment -

          There was code for this situation but it didn't cover the case 100%.
          Now if a request to page2?0 is made and the type of the found page with id=0 is not Page2 then a new instance of Page2 is instantiated.

          Show
          Martin Grigorov added a comment - There was code for this situation but it didn't cover the case 100%. Now if a request to page2?0 is made and the type of the found page with id=0 is not Page2 then a new instance of Page2 is instantiated.
          Hide
          Bertrand Guay-Paquet added a comment -

          Confirmed working

          Show
          Bertrand Guay-Paquet added a comment - Confirmed working

            People

            • Assignee:
              Martin Grigorov
              Reporter:
              Bertrand Guay-Paquet
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development