Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-5270

Do not set the location.hash when clicking on a link

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 6.9.0
    • Fix Version/s: 6.10.0, 7.0.0-M1
    • Component/s: wicket
    • Labels:
      None

      Description

      Clicking an AjaxLink or SubmitLink sets the location.hash to an empty value (..../someUrl?some=param#).
      This interferes with JavaScript libraries which need to use 'hashchange' event.

      Additionally in two of our apps we experience a strange page reloads after clicking on AjaxLink.
      The issue is not easy to reproduce but it seems to be caused by the used href="#" somehow.
      Applying a custom behavior that overrides href="#" with href="javascript:;" fixes the problem.

      The problem occurred on Google Chrome and IE9 so far.

        Attachments

          Activity

            People

            • Assignee:
              mgrigorov Martin Grigorov
              Reporter:
              mgrigorov Martin Grigorov
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: