How can a servlet refresh automatically if some new data
has entered the database?
Answer Posted / vikas kapoor
Well you can use
response.setHeader("Refresh",5);
This will update the browser after every 5 seconds
response.setHeader("Refresh","5",
URL="http://localhost:8080/myServlet/MyRequest.do
This will refresh MyRequest.do after 5 seconds
| Is This Answer Correct ? | 28 Yes | 0 No |
Post New Answer View All Answers
Why is init() method is used in servlets?
How to commuincate between an applet and a servlet?
How can we achieve transport layer security for our web application?
Which protocol will be used by browser and servlet to communicate
What is the use of java servlet api?
What are the steps that are required to handle the multi-threading?
What is the use of httpservletresponsewrapper?
Explain servlet.
Explain the difference between generic servlet and http servlet?
How to make sure a servlet is loaded at the application startup?
What do you mean by httpservlet and how it is different from the genericservlet?
How are filters?
What do you mean by deployment descriptor?
how many jsp scripting elements are there and what are those?
Write the code to get the server information in servlet.