• Post Reply Bookmark Topic Watch Topic
  • New Topic

Data not refrshing

 
naga eswar
Ranch Hand
Posts: 128
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

In our application we are using XML,JSP,HTML, servlets for front end and DB2 as backend.

We are facing typical issue that once we are submitign data, its saving at the backend but not reflecting on the screen immediately.

For example, employee raised leave and its reflects on the screen of his RM's login.
Once he(RM) approved by clicking on the approve button, at the backend it updates that recored as "approved" and dissapears on the RM's screen.

But here once RM approved, the record is updating fins at the bankend. But still it showing as "Pending". once RM logout and login then only it is refreshing.

I hope the page is not refreshing with data immediately. Can any body help me please. How to refresh the page with data immediately.
 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A page that has already been generated will not refresh unless you make make it do so (either using "refresh/reload" in the browser, or inserting some AJAX/JavaScript code in the page that checks for updated data).

If you do either of these, and it still doesn't show the updated data, then it would seem that there is some caching going on somewhere.
 
Sourabh Bawage
Ranch Hand
Posts: 33
Eclipse IDE Java Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
anything that is not visible to the user is backend....so just database is NOT backend......
 
Sourabh Bawage
Ranch Hand
Posts: 33
Eclipse IDE Java Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
this might be helpful...

http://javapapers.com/ajax/getting-started-with-ajax-using-java/
 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
http://javapapers.com/ajax/getting-started-with-ajax-using-java/

While it's not clear that naga eswar has (or wants) an AJAX solution, this is definitely not the way to do it. Using XMLHttpRequest directly (as opposed to via a framework like Prototype or jQuery) has fallen out of fashion years ago.
 
Sourabh Bawage
Ranch Hand
Posts: 33
Eclipse IDE Java Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ulf Dittmer wrote:
http://javapapers.com/ajax/getting-started-with-ajax-using-java/

While it's not clear that naga eswar has (or wants) an AJAX solution, this is definitely not the way to do it. Using XMLHttpRequest directly (as opposed to via a framework like Prototype or jQuery) has fallen out of fashion years ago.


Indeed, i just wanted him to begin with ajax (i had an impression that he isn't aware of ajax)...
 
naga eswar
Ranch Hand
Posts: 128
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you very much for your inputs guys.

@Sourabh Bawage .... what is said is right i didnot worked much on Ajax. Only once I have used to call servlet through Ajax for validation and again to take response from it.

Now can you help me how ajax helps me to refresh page.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!