Some of my Ajax requests fail (e.g. when navigating between Product Categories), typically when the server response time exceeds 5 sec. There seem to be some timeout defined in JS launching the request, and if timeout expires, the JS loads the target page as a fallback.
Where is this timeout defined? I would like to set it to more than 5 sec.
Thanks š
Note: relevant file seems to be basel/js/libraries.js…
Yes, there is a 5s timeout for AJAX requests and you can increase it in the file js/functions.js. But to see changes you will need to disable JS minification in Theme Settings -> Performance.
Thanks. I want to keep my JS files minimized, would you consider changing this timeout to, say, 10 sec?
Taking more than 5 sec to load a WC page is not unusual on a shared hosting server like probably some other Basel users have.
Or maybe there would be some drawbacks I am not aware of…
Actually, 5s is too long and there is some issue with your hosting performance or with some of installed plugins. In this situation, we suggest you to improve your website speed or disable AJAX shop option at all.