jQuery performance in IE7
J.Fine
J.Fine at open.ac.uk
Wed Jan 28 14:34:23 UTC 2009
Hello Lovemore
Here's how you've constructed a string.
var params = 'item-text=' + itemText;
params +=
'&item-text-fossil=istring%23%7BtemplateItemWBL.new1.item.itemText%7D';
params +=
'&showItemCategory%3A%3Aitem-category-list-selection-fossil=istring%23%7
BtemplateItemWBL.new1.category%7DCourse';
params +=
'$showItemCategory%3A%3Aitem-category-list-selection=' + category;
params +=
'&idealColor-fossil=iboolean%23%7BtemplateBBean.idealColor%7Dfalse';
params += '&idealColor=' + idealColour;
params +=
'&item_NA-fossil=iboolean%23%7BtemplateItemWBL.new1.usesNA%7Dfalse';
params += '&item_NA=' + usesNA;
var ordering = new Array();
ui.item.parents('.itemTableBlock').eq(0).children('.itemRowBlock').filte
r(':visible').each(function() {
var val =
$(this).children('input[name=hidden-item-id]').eq(0).val();
params += '&hidden-item-id=' + val;
ordering.push(val);
});
params += '&templateItemIds=' +
ordering.toString();
params += '&ordered-child-ids=' +
ordering.toString();
params +=
'&ordered-child-ids-fossil=istring%23%7BtemplateBBean.orderedChildIds%7D
';
params += '&templateId=' + t.attr('templateid');
params +=
'&command+link+parameters%26el-binding%3Dj%2523%257BtemplateBBean.blockI
d%257Dnew1%26el-binding%3Dj%2523%257BtemplateBBean.templateItemIds%257D'
+ ordering.toString() +
'%26el-binding%3Dj%2523%257BtemplateBBean.originalDisplayOrder%257D2%26S
ubmitting%2520control%3DsaveBlockAction%26Fast%2520track%2520action%3Dte
mplateBBean.saveBlockItemAction=Save+item';
Here's a quicker way to do the same sort of thing
// Top level.
var template = ['xxx', 0, 'yyy', 1, 'zzz', 2, 'etc'];
// In loop.
template[1] = 'wibble';
template[3] = 'wobble';
template[5] = 'foozle';
var value template.join('');
There are other things you might try, but I think this would be a good
start.
Jonathan
________________________________
From: fluid-talk-bounces at fluidproject.org
[mailto:fluid-talk-bounces at fluidproject.org] On Behalf Of Lovemore
Nalube
Sent: 28 January 2009 07:29
To: Colin Clark
Cc: fluid-talk at fluidproject.org
Subject: Re: jQuery performance in IE7
Hey Colin,
Here's the actual code:
https://source.sakaiproject.org/contrib/uct/evaluation-pilot08-UI/tool/s
rc/webapp/content/js/reorderUtils.js.
************************
Lovemore Nalube
Online Learning Environments Developer
Centre for Educational Technology
University of Cape Town
www.cet.uct.ac.za
/* Work Email: lovemore.nalube at uct.ac.za
/* Cell: 076 186 1244
/* GTalk: lovenalube at gmail.com
On Tue, Jan 27, 2009 at 6:28 PM, Colin Clark <colin.clark at utoronto.ca>
wrote:
Lovemore,
On 27-Jan-09, at 2:15 AM, Lovemore Nalube wrote:
I've reached a stage in which the preliminary phase nears completion,
however when testing the UI in IE7, there is a huge performance
overhead. FF3 seems to hold the load quite easily. In a nutshell what
freezes the browser is trying to filter through a response object to get
elements that exist within and then show these on the UI. Has anyone
ever had issues with jQuery performance/freezing the browser like this?
I invite you to checkout the code at
https://source.sakaiproject.org/contrib/uct/evaluation-pilot08-UI. The
page with the new UI is Evaluations dashboard > My Templates > Edit
Template
Do you have a link to the specific JavaScript source code that you're
seeing the problem in? We can probably lend a hand in optimizing your
implementation.
Colin
---
Colin Clark
Technical Lead, Fluid Project
Adaptive Technology Resource Centre, University of Toronto
http://fluidproject.org
---------------------------------
The Open University is incorporated by Royal Charter (RC 000391), an exempt charity in England & Wales and a charity registered in Scotland (SC 038302).
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://fluidproject.org/pipermail/fluid-talk/attachments/20090128/df3c7032/attachment.html>
More information about the fluid-talk
mailing list