Today my colleague, Al-Amin Rubel, faces a interesting (but very common of course) problem –
“Pages are not being reloaded/ refreshed after contents are updated by
After debugging a lot, it was clear that whenever request URL of
Solution:
So, perhaps the best solutions is to change the url every time. Don’t afraid, this is very simple, just add a url variable with random value using random() function.
Example:
Suppose, your
Then change it by adding a variable with random value – like
‘ajaxresponse.php?name=xyz&res=123&rnd=’+Math.random(10);
That’s it, solved!
This is because browser takes the url as a new request (url) every time.
No comments:
Post a Comment