English 中文(简体)
Can t 获得美国宇宙航空研究开发机构的请求,在互联网探索者中装上不止一次的仪器
原标题:Can t get AJAX request to load more than once in Internet Explorer

I have been messing with this code for quite some time, works in FF, Chrome, Safari but IE for some reason will only load one time. I have tried using the time function as well as the math.random function in the querystring to make the URL unique. I used firebug to make sure that my math.random function was working correctly and it seems to be but for some reason IE will only load the page once. I am about to pull my hair out and abandon the whole idea, please help!!

法典如下:

$.ajaxSetup ({
    // Disable caching of AJAX responses
    cache: false
});


var myHandle = setInterval(function () {
    $.ajax({
        type: "POST",
        url:  randomize2.php?ck=  + Math.random(),
        cache: false,
        success: function (data) {
            // data is ur summary
            $( #dispeople ).html(data);
        }
    })
}, 2000);

 var mybutton2 = document.getElementById("mybutton2");

建议 我检查了IEE开发商的工具,发现该守则在以下代码栏中进一步细分:

$(function() {
    setInterval(function() {
        $( .all ).quicksand( $( .warm li ), {
            duration: 1000,
            attribute:  id ,
            easing:  easeInOutQuad 
        });
        e.preventDefault();
    }
    }, 5000);
});
最佳回答

现在,我编篡了该法典,错误(可能不会<><>>>>/em>错误) jump出:

$(function() {
    setInterval(function() {
        $( .all ).quicksand( $( .warm li ), {
            duration: 1000,
            attribute:  id ,
            easing:  easeInOutQuad 
        });
        e.preventDefault();
    } // <========================= Extra } here
    }, 5000);
});

I can t imagine Chrome or the others running that code.

问题回答

你们是否尝试过这一法典?

// Disable browser cache Ajax.ActionLinks
$.ajaxSetup({ cache: false });

IE6,7 are more sensitive with javascript code s quality, like ; , var missing problems.

Use Fiddler to monitor activity. You can then check if the query strings are actually different. I suspect ie might be serving the request of its cache.





相关问题
selected text in iframe

How to get a selected text inside a iframe. I my page i m having a iframe which is editable true. So how can i get the selected text in that iframe.

How to fire event handlers on the link using javascript

I would like to click a link in my page using javascript. I would like to Fire event handlers on the link without navigating. How can this be done? This has to work both in firefox and Internet ...

How to Add script codes before the </body> tag ASP.NET

Heres the problem, In Masterpage, the google analytics code were pasted before the end of body tag. In ASPX page, I need to generate a script (google addItem tracker) using codebehind ClientScript ...

Clipboard access using Javascript - sans Flash?

Is there a reliable way to access the client machine s clipboard using Javascript? I continue to run into permissions issues when attempting to do this. How does Google Docs do this? Do they use ...

javascript debugging question

I have a large javascript which I didn t write but I need to use it and I m slowely going trough it trying to figure out what does it do and how, I m using alert to print out what it does but now I ...

Parsing date like twitter

I ve made a little forum and I want parse the date on newest posts like twitter, you know "posted 40 minutes ago ","posted 1 hour ago"... What s the best way ? Thanx.