If Internet goes down while we make a Ajax Request then how to give feedback to the user that the internet is down ?
You can define a timeout on AJAX request, if timeout is reached you can then choose best way to display the error message to the user.
BTW, you cannot be certain that internet connection is down, so a standard message could be:
Unable to contact server at url: 'http://myapp.com'.
Please be sure your internet connection is working
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With