in Education by
I'm playing around with ASP.net MVC and JQuery at the moment. I've come across behavour which doesn't seem to make sense. I'm calling JQuery's $.getJSON function to populate some div's. The event is triggered on the $(document).ready event. This works perfectly. There is a small AJAX.BeginForm which adds another value to be used when populating the divs. It calls the remote function correctly and upon success calls the original javascript function to repopulate the divs. Here is the weird part: In FireFox and Chrome - Everything works. BUT In IE8 (Beta) this second call to the populate Div script (which calls the $.getJSON function) gets cached data and does not ask the server! Hope this question makes sense: In a nut shell - Why is $.getJSON getting cached data? And why is it only effecting IE8? JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)

1 Answer

0 votes
by
This is how it worked for me... $.ajaxSetup({ cache: false }); $.getJSON("/MyQueryUrl",function(data,item) { // do stuff with callback data $.ajaxSetup({ cache: true }); });

Related questions

0 votes
    I have a auto complete box set up. however when a user types in the box a list of every single ... , JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Feb 13, 2022 in Education by JackTerrance
0 votes
    I have a auto complete box set up. however when a user types in the box a list of every single ... , JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Feb 13, 2022 in Education by JackTerrance
0 votes
    The ____________ Domain Name Server data will get spread to the ISPs & will be cached there. (a) working ... -for-Cyber Security:,Cyber Security-Jobs:,Cyber Security Applications...
asked Oct 31, 2021 in Education by JackTerrance
0 votes
    I have a web application that uses the current version of JQuery that needs to get some JSON objects back ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 11, 2022 in Education by JackTerrance
0 votes
    Heres my Situation. Im trying to relaod a div in a page with load(). I first tryed with a GET. ... , JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Feb 19, 2022 in Education by JackTerrance
0 votes
    I have noticed that some browsers (in particular, Firefox and Opera) are very zealous in using cached ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 17, 2022 in Education by JackTerrance
0 votes
    I am have a working webdriverio framework which executes without any issue. But recently I included a REST ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked May 13, 2022 in Education by JackTerrance
0 votes
    I'm using $.ajax() to load new pages on my site if certain conditions are met (a flash-based ... , JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Mar 4, 2022 in Education by JackTerrance
0 votes
    $ (a) Which of the following is used to change the color of hyperlink from blue to any other color? (i) Link ... (iv) none of these 00 Select the correct answer from above options...
asked Nov 30, 2021 in Education by JackTerrance
0 votes
    The $' present in the RegExp object is called a ____________ (a) character (b) matcher (c) ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 23, 2021 in Education by JackTerrance
0 votes
0 votes
    What is the use of "$?" sign in shell script?...
asked May 28, 2021 in Technology by JackTerrance
0 votes
    What is the use of "$?" sign in shell script?...
asked Jan 19, 2021 in Technology by JackTerrance
0 votes
    In the code below, in "parse" function I am trying to get substring from the string "line". I am ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Jun 16, 2022 in Education by JackTerrance
0 votes
    In the code below, in "parse" function I am trying to get substring from the string "line". I am ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Jun 5, 2022 in Education by JackTerrance
...