Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_Related Related Topics sp_TopicIcon
memory leak when switching between pages?
28/04/2010
04:56
Avatar
michaelg
Member
Members
Forum Posts: 51
Member Since:
10/04/2010
sp_UserOfflineSmall Offline

Hi All,

First i just want to say that I love jqgrid - ive been using it for a few weeks now and think its awesome 🙂

I'm trying to make a large web application, and have hit a wall in regards to memory leaks.  I find that my browser chews up memory quite alot. 

As an example, I have a simple page with a jqgrid in it with paging enabled.  Using sieve, i find that when i switch from page 1 to 2, then back to 2, and keep doing that, then rows are not released from memory and the DOM count just keeps building.

I'm using a function for the grid's datatype, which gets the data using AJAX and uses thegrid.addJSONData().  Could this be the problem.

Has anyone else had these sorts of issues?  Its driving me nuts 🙂

Cheers,

Michael

28/04/2010
11:08
Avatar
michaelg
Member
Members
Forum Posts: 51
Member Since:
10/04/2010
sp_UserOfflineSmall Offline

Oh, i forgot to add this (it might help) ...

function getData(postdata) {
    
    $.ajax({
        type: "POST",
        url: dataURL,
        data: JSON.stringify(postdata),
        dataType: "json",
        contentType: "application/json; charset=utf-8",

        success: loadGrid,
        error: function() { alert('error'); }
    });
}

function loadGrid(jsondata) {
    var thegrid = $(gridName)[0];
    thegrid.addJSONData(jsondata.d);
}

Smile

29/04/2010
03:04
Avatar
michaelg
Member
Members
Forum Posts: 51
Member Since:
10/04/2010
sp_UserOfflineSmall Offline

I've been looking into this for hours, one interesting thing ive found is that the DOM elements that are left lying around are <TR> and <TD> elements with no parent.  Does anyone know of a manual way of deleting these?  I can't seem to access them in javascript, but the sieve tool shows that they're still hanging around (and build up each time i switch pages)

Yell

06/05/2010
14:50
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello,

This is corrected in 3.6.5. Also we introduce a new parameter - deepempty - see what is new.

Regards

Tony

For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.

07/05/2010
02:11
Avatar
michaelg
Member
Members
Forum Posts: 51
Member Since:
10/04/2010
sp_UserOfflineSmall Offline

Hi Tony,

Thanks very much for that.  I love your work 🙂

Cheers,

Michael

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
29 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

OlegK: 1255

markw65: 179

kobruleht: 144

phicarre: 132

YamilBracho: 124

Renso: 118

Member Stats:

Guest Posters: 447

Members: 11373

Moderators: 2

Admins: 1

Forum Stats:

Groups: 1

Forums: 8

Topics: 10592

Posts: 31289

Newest Members:

, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information