This article will introduce some of the problems that sometimes have problems in the return values of jquery ajax in IE browser.
Question 1,
A function of the website. After a parameter is updated using JQuery, another $. get method is used to obtain the updated value, which will become invalid for the second time in IE.
The final problem is that IE uses the last GET returned result cached locally to directly respond to the next request.
You can solve this problem after modifying it to $. post.
Question 2,
Today, we are dealing with the problem of partial page refresh. other browsers are normal, but there is no returned value under IE. After investigation, it turns out that the cache is still cool. Then we add a parameter to the script, as shown below:
The Code is as follows: |
Copy code |
$ (Document). ready (function (){ SetInterval ('wb _ Get () ', 5000 ); }); Function Wb_Get () { $. Get ( "/Index. php? Id = "+ $ (" # video_id "). val () +" & v = "+ escape (new Date ()), Function (data) { If (data) { $ ("# Live_list_ul"). prepend (data ); } } ); } |
The v parameter transmits a value similar to a random number to obtain the latest content.