0

i'm writing a web application with Java (with spring/mvc). To navigate from page to page i use this:

function toPage() {
    window.location.href = 'profilo.htm';
    return false;
}

triggered by a button. This function call a servlet and the servlet do this:

public class HomeServlet extends AbstractController {

    @Override
    protected ModelAndView handleRequestInternal(HttpServletRequest request, HttpServletResponse response) throws Exception {
        ModelAndView model = new ModelAndView("profilo");

        return model;
    }


}

And after this servlet i'm in profilo.jsp.

Now if i press the back button of my browser i get the alert of the module/post submission.

What i can do to prevent this?

Thanks

Alist3r
  • 556
  • 3
  • 11
  • 27
  • possible duplicate of [Prevent Back button from showing POST confirmation alert](http://stackoverflow.com/questions/660329/prevent-back-button-from-showing-post-confirmation-alert) – TJ- Aug 26 '14 at 13:28
  • @TJ- i read this before posting.. i need some better help. plz – Alist3r Aug 26 '14 at 13:45

0 Answers0