Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

Which are the different ways you can communicate between servlets?

953


How do you configure a centralized error handler in servlets?

1050


What is Servlets and explain the advantages of Servlet life cycle?

1050


How do servlets work?

983


How does tomcat servlet container work?

1029


How can we upload the file to the server using servlet?

1017


Differentiate between the get and post method

1020


Name the different ways of session tracking.

968


What is meant by session? Tell me something about httpsession class?

970


What are the phases of servlet life cycle?

1068


What is servlet instance?

998


Can you refresh servlet in client and server-side automatically?

1039


How do you deal property files in servlet?

1025


Whether we can get deadlock situation in servlets?

1021


Explain the differences between jsp and servlet.

951