...

View Full Version : After Abort all executions blank



pg300
09-09-2008, 09:27 AM
I'm having a problem. I created a timeout feature using the abort() function. It timesout and aborts great. But when it comes time to reuse it, it returns blank O_O anyone ever had this problem?

If i dont abort it reusing it is not a problem. Is there something i have to do before resuing it after an abort()?

Thanks!

A1ien51
09-09-2008, 03:36 PM
Not sure what you are saying the issue is.

So you are reusing the XMLHttpRequest Objects.

Can you show us some code?

Eric

pg300
09-10-2008, 12:38 AM
actually i think i know the problem.
It works fine in firefox but in ie6 it causes problems on my site and other sites.
See this:
http://home.arcor.de/martin.honnen/mozillaBugs/XMLHttpRequest/abortChangesReadyState4.html
I cant figure out why but if you go there and set test state as 2 or 3 or 4. It says readystate changed to 1 and just sits there :(
Do you know what could be causing that?
Once it starts the send it just sits there. The testcase only returns succesfully aborted on 1 because it is the 1 before sending. The order of readysates is 1, 1, 2, 3, then 4 right?

pg300
09-10-2008, 01:06 AM
oh my gosh i found the problem. it wasn't the ajax. it was this stupid preloader script. I wrote:

if (document.images) {

if (npPreloadImg.src != 'http://www.neocodex.us/forum/sources/action_public/ncdx/navbutton.php?number='+(1 + parseInt(npThisPage))+'s'+npTotalPages) {
//alert('loading wanted pic into npPreloadImg');
npPreloadImg.src='sources/action_public/ncdx/navbutton.php?number='+(1 + parseInt(npThisPage))+'s'+npTotalPages;
if (!npPreloadImg.complete) {
//alert('just loaded our pic into npPreloadImg and its not in cache so will setimout:'+npPreloadImg.src);
setTimeout("np_next()",100);
return;
} else {
//alert('we just loaded and its already in cache so continue:'+npPreloadImg.src);
}
} else {
if (!npPreloadImg.complete) {
//alert('our pic is still not loaded so will try again in 100ms:'+npPreloadImg.src);
setTimeout("np_next()",100);
return;
}
//alert('npPreloadImg we want is loaded:'+npPreloadImg.src);
}
}

Sorry guys



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum