0

I am having a dynamic content in my jsp pages that has to be refreshed once my form is submitted.Form submission is not done via ajax.I have tried with data-cache=never,rel=external. They ddnt work for me.

Reporter
  • 3,897
  • 5
  • 33
  • 47
karthiga
  • 11
  • 2
  • 3
  • What have you done so far. Please be more specific and maybe post also code. – Reporter Aug 01 '11 at 07:13
  • 1
    _They ddnt work for me._: Did the page not refresh at all? Did the form submit at all? Did the page refresh but with old data (from cache)? You will have to say what happened that you did not expect. And show us how you submit the form – Nivas Aug 01 '11 at 07:14

2 Answers2

1

Use

location.reload(true);

in javascript.

nidhin
  • 6,661
  • 6
  • 32
  • 50
  • after form submission,my success page is appearing.But when I click on Back button, the page with old data from cache appears and not with the dynamic data that is fetched out of my backend functionality that i have implemented on click of submit. – karthiga Aug 01 '11 at 07:22
0
$('#my_form').submit(function(){
    // After everything else...
    window.location.reload();
});
AlienWebguy
  • 76,997
  • 17
  • 122
  • 145