Home Forums Basel support forum Ajax Request Timeout

Ajax Request Timeout

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #25347

    altitudes89
    Participant

    Hello,

    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…

    #25356

    Artem Temos
    Keymaster

    Hi,

    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.

    Regards

    #25384

    altitudes89
    Participant

    Hello

    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…

    #25413

    Artem Temos
    Keymaster

    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.

Viewing 4 posts - 1 through 4 (of 4 total)