Firefox Ajax limit of 4096?
Hi Everyone,
Perhaps this is something easy, but I haven't been able to find an answer yet. My site is looking good with IE, however, in Firefox, when I make some simple Ajax Web Service calls for some HTML content, they are successful but limited to 4096 characters...whereas IE is unaffected. FF truncates my content to 4096. When I look at Firebug, it appears as though the full text/html content is coming back to the client, so maybe it's the coolite method "selectValue"?
Code:
function onUpdateNewsFeedsSuccess(result)
{
var strResult=Ext.DomQuery.selectValue("string", result, "");
alert(strResult.length);
if (strResult!=""){
var elem;
if (strResult.indexOf("|~|")!=-1)
{
var resultParts = strResult.split("|~|");
var sentMode = resultParts[0];
var content = resultParts[1];
if (sentMode.toUpperCase()==activeMode.toUpperCase())
{
var newsFeedsPanel = Ext.getCmp("ctl00_MainContentPlaceHolder_NewsFeedsTab");
newsFeedsPanel.getBody().update(content);
}}
}
}
}
}
RE: Firefox Ajax limit of 4096?
Yeah, it seems like a bug with
Ext.DomQuery.selectValue
Firefox and IE seem to return different xml structures, so when you call the selectValue method to retreive the text/xml content, it must not be retrieving the correct node item from the XML document. This is just a guess for now until someone from the coolite team confirms...
Dan
RE: Firefox Ajax limit of 4096?
I created a JS function to handle the "result" from the web service ajax call...which works in both FF and IE...
just call that instead of...
var strResult=Ext.DomQuery.selectValue("string", result, "");
Code:
function getWebSvcString(result)
{
var strResult="";
var stringElement = result.getElementsByTagName("string")[0];
if (stringElement.text!=null && stringElement!=undefined){
strResult=stringElement.text;
// alert("IE: "+strResult.length);
}
else if (stringElement.textContent!=null && stringElement.textContent!=undefined)
{
strResult=stringElement.textContent;
// alert("FF: "+strResult.length);
}
return strResult;
}