Do you have a sample page? There are several other ways to build the table, but it would be good to make sure the problem you think you're seeing is really the problem you have.
-----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of halfer Sent: Monday, February 05, 2007 6:19 AM To: discuss@jquery.com Subject: [jQuery] ('#id').prepend() slow on IE6 in large tables Hello all, new poster to the list here (resending via Nabble after subscribing!). I am using jQuery 1.1.1 to load table data via an AJAX op into a page, and am running into some performance issues, especially with IE6. I have read here and elsewhere that IE presents some speed issues with DOM manipulation, but haven't found much information to deal with the problem. I am loading about 100Kb of JSON data via an AJAX POST, which resolves to a ~500 x 4 array. This is rendered as a standard table, so I am using prepend(html) on an empty tbody element using a simple #id selector. To reduce the CPU load, I employ setInterval() to progressively prepend X rows every Y seconds, and have found in Firefox, 50 rows every 1 second loads without significant slowdown. However the same in IE causes the processor to max out after 350-400 rows have been added, freezing the animated GIF wait indicator and preventing the browser from responding to window redraw requests for some 10-20 seconds. In fact, trying to prepend too much even in Firefox (ie a few hundred rows in one go) results in a maxed out CPU or even, occasionally, a completely frozen browser. My dev machine is 2.4GHz P4 / 1Gb RAM / WinXP Pro, so it's not the computer (I hope!). Firstly, do I need to be aware of any special rules regarding DOM amendment within setinterval/settimeout callbacks, in any/all browsers? Secondly, is there a way to avoid prepend/append? I understand that innerHtml is available, but I am not sure whether that's standards compliant or particularly cross-browser. Thanks in advance to all respondents. -- View this message in context: http://www.nabble.com/%28%27-id%27%29.prepend%28%29-slow-on-IE6-in-large-tab les-tf3173727.html#a8804514 Sent from the JQuery mailing list archive at Nabble.com. _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/ _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/