Browsers (IE and Firefox) freeze when copying large amounts of text
I have a web application - a Java servlet that delivers data to users as a text printout in the browser (the text is tagged as HTML for display in the browser as we want). The text is displayed in different colors, although most of it is black. One typical mode of operation:
1. The user submits a form to request data.
2. The servlet delivers the HTML file to the browser.
3. The user performs CTRL + A to select all the text.
4. The user executes CTRL + C to copy all the text.
5. The user goes to the text editor and makes CTRL + V to paste the text.
In testing where I am having this problem, step # 2 successfully loads all the data - we are waiting for completion. We can scroll to the end of the browser loading and see the end of the data. However, the browser freezes at step 3 (Firefox) or step 4 (IE). Since stage # 2 ends, I think it is a browser / memory issue and not a web application issue.
If I run requests to deliver less data (but after multiple requests we get the same data that would have been higher in one request) and copy / paste this text, the file I saved ends up at about 8MB if I save browser displaying HTML to a file on my computer using File-Save As from the browser menu, it works fine and the file is about 22MB.
( Windows XP, 2 GB ), Firefox IE. (, , ), Windows 7 IE, . , , , 50%. Firefox 1 ; IE . , .
I am most likely going to modify the web application to be able to deliver a simple text file for download, and I believe users will get what they want. But for an average time, and because I'm curious - and I don't like it when my app freezes people's browsers, does anyone have any ideas about freezing the browser? I understand that sometimes you just hit your memory limit, but it seems to me that 22MB sounds like the amount I should copy to the clipboard.
a source to share