[jQuery] Prevent IE Cross Page Leak

[jQuery] Prevent IE Cross Page Leak

<div dir="ltr"><div>Hi all, </div><div>
</div><div>I have some question about IE memory leakage.</div><div>
</div>There are four type of leakage in IE as stated in <a href="http://msdn.microsoft.com/en-us/library/bb250448(VS.85).aspx">http://msdn.microsoft.com/en-us/library/bb250448(VS.85).aspx</a><div>
One of them is called 'Cross Page Leak', which is caused by DOM insertion order. (should have no intermediate object)</div><div>The result is that the memory will not be released even if page is changed.</div><div>
</div><div>So, will the following code introduce this kind of leakage?</div><div>
</div><div>$('<div>')</div><div>    .append('

Some text

')</div><div>    .append($('<div/>').append('abcdef'))</div>
<div>        //more append to create the complex dom objects</div><div>        //.....</div><div>    .appendTo("body");
</div><div>
</div><div>My case is quite serious. I have a page with some modals displaying some small search box the ajax way.</div>
<div>Whenever a modal is displayed, about 10MB of memory is consumed and it never returns.</div><div>
--
Best Regards,
Jacky
網絡暴民 <a href="http://jacky.seezone.net">http://jacky.seezone.net</a>
</div></div>