1

I want to show the contents of a log file which is constantly updating in the back ground in my HTML page in real time. I am using jQuery. Is there any jQuery plugins to do so. I have Websockets but those doesn't work in our existing framework. Please suggest any ideas or links.Thanks

Sukant M
  • 35
  • 8

1 Answers1

0

You can use AJAX and setInterval.

setInterval(function(){
 getlog();
}, 2000);

If websockets doesn't exists in your existing framework this is the best.

You can also try out Long Polling with AJAX. Maybe the answer for this question will help you: Simple long polling example with JavaScript and jQuery

Community
  • 1
  • 1
Beardminator
  • 784
  • 8
  • 20