Currently, I am working on developing an android application using HTML & JS. After successful development, I plan to use PhoneGap for this project. One of the key features I want to implement is having the app alert the user when their device is not connected to WiFi or Mobile data, and then automatically close after displaying the alert.
I checked out a solution on Stack Overflow for reference: How to alert the user when there's no internet connection
Unfortunately, the suggested solution did not work for me. If anyone has an alternative solution for achieving the same functionality, please do share your suggestions.