AJAX get data from large HTML page as the large HTML page loads

Posted by Ed on Stack Overflow See other posts from Stack Overflow or by Ed
Published on 2010-06-03T12:49:35Z Indexed on 2010/06/03 12:54 UTC
Read the original article Hit count: 628

Filed under:
|
|
|
|

Not entirely sure whether this has a name but basically I have a large HTML page that is generated from results in a db.

So viewing the HTML page (which is a report) in a browser directly does not display all contents immediately but displays what it has and additional HTML is added as the results from the DB are retrieved...

Is there a way I can make an AJAX request to this HTML page and as opposed to waiting until the whole page (report) is ready, I can start processing the response as the HTML report is loaded? Or is there another way of doing it?

Atm I make my AJAX response it just sits there for a minute or two until the HTML page is complete...

If context is of any use: The HTML report is generated by a Java servlet and the page making the AJAX call is a JSP page. Unfortunately I can't very easily break the report up because it is generated by BIRT (Eclipse reporting extension).

Thanks in advance.

© Stack Overflow or respective owner

Related posts about java

Related posts about JavaScript