ajax cach




Wordpress LScache Plugin: ajax cach

Last Updated on: Wed, 15 Apr 2026 00:00:02
Hi on my site for logging, the user has to click a button. a modal window appears. after that users have to click to the login button. it works with ajax. for some user the modal windows become freeze. can I stop caching ajax? Hi, ajax doesnt get cached , you can verify it by HTTP response header, for any ajax call you should see x-litespeed-cache-control: no-cache on it. when it freezes, do you see any error message ? what is the status code on that ajax request ? this is more like nonce issue. Best regards, I use this code after successful login response = JSON.parse(response) if(response.status == success) formSuccessArea.html(response.message) location.reload() it just reloads the page and doesnt log in! I change to location.replace(/profile) I realize when the plugin is active replace method after login does not work. but as soon as disable the plugin. users after logging redirects to profile page. by the way the result of console.log(currentAjax.getAllResponseHeaders()) is access-control-allow-credentials: true access-control-allow-origin: https://www.my.com cache-control: no-cache, must-revalidate, max-age=0 content-encoding: br content-length: 125 content-type: text/html charset=UTF-8 date: Mon, 14 Dec 2020 13:23:29 GMT expires: Wed, 11 Jan 1984 05:00:00 GMT referrer-policy: strict-origin-when-cross-origin server: LiteSpeed vary: Accept-Encoding x-content-type-options: nosniff x-firefox-spdy: h2 x-frame-options: SAMEORIGIN x-litespeed-cache-control: no-cache x-robots-tag: noindex Expand Hi, when you successfully logged in , did you see , by dev tool , _lscache_vary cookie being sent/set ? x-litespeed-cache-control: no-cache ?> this shows that request is not being cached. I change to location.replace(/profile) I realize when the plugin is active replace method after login does not work. but as soon as disable the plugin. users after logging redirects to profile page I think might be the JS code is being cached could you please try login_redirect hook and see how that goes ? Best regards, login_redirect hook works. thanks



LiteCache Rush: Speed comes from using less, not from doing it faster



Reference