SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Member
    Join Date
    Apr 2008
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Memory leak w/ iframes & AJAX

    I'm working on my first AJAX application, and I'm having some HUGE memory leak issues in IE6/7, as well as some usability issues too.

    It works absolutely perfect in FF...it does use up some memory after a while, but nothing terrible. But, in IE6 & 7, it gets up to 300MB after about an hour (which, it will be view for about 1.5-2 hrs straight at a time).

    Also, the chat box keeps freezing up on IE6/7 users too, most likely due to the AJAX, which I can't figure out why.

    Can anyone see what I could possibly do to prevent this? I've tried different things, different methods, but I can't figure it out. The site's located at www (DOT) thextremepaintballleague (DOT) com/live-new/?mid=106 (sorry about the link...damn sitepoint won't let me post a link)

    Any help would be greatly appreciated.

  2. #2
    We're from teh basements.
    Join Date
    Apr 2007
    Posts
    1,205
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    If you are appending messages to a document in the iframe, you're building a huge document over time. That's where the memory is going. Try removing the first child if there are more than, say, fifty child elements. That will keep the number of posts "remembered" below fifty.

  3. #3
    SitePoint Member
    Join Date
    Apr 2008
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Ok...how would I go about doing that though? I've been going through google all morning, and I'm confused as to how to actually do that.

    Thank you,

    Scott

  4. #4
    SitePoint Member
    Join Date
    Apr 2008
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    here's a page I'm trying to delete the elemnts on, but I'm not having any luck:

    www (DOT) thextremepaintballleague (DOT) com/live-new/java_chat.js

    Any suggestions?

    Thanks,

    Scott


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •