Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7926799
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T18:57:02+00:00 2026-06-03T18:57:02+00:00

I need to understand while my web app working if browser is connect to

  • 0

I need to understand while my web app working if browser is connect to internet or not. This mean I have to use cloud data or localstore one.

When i use navigator.onLine only chrome tell me the truth. Firefox or Safari only check if I am connect to wi-fi.

I create a function that send a ping to a specific website and try to download a little file every time, but if I use my web app on a mobile this is not a good solution.

Can anyone can tell me another idea?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T18:57:04+00:00Added an answer on June 3, 2026 at 6:57 pm

    It depends what you mean by ‘connected to the internet’. There are so many points on the path from your browser to a server resource which could fail. Is it your local connection? A problem at your default gateway? A routing problem on the wider network? A problem with the server application you’re trying to access?

    The only way to be absolutely sure that the resource you need is available, with no issues anywhere on the journey, is to try to obtain the resource you need. But it could be quite slow to check this if you’re having to wait for timeouts before determining that there really is a problem.

    Have you considered a different approach to running a browser application offline, whereby you always persist data to localstore and regularly synchronise it to the server asynchronously? You could provide feedback to the user as to whether or not the sync to the server was successful, but be satisfied that data would always get saved locally regardless.

    I know of one library which helps with this, that being the new Microsoft Single Page Application framework. Surely there must be other non-Microsoft equivalents too.

    EDIT: This looks like a very interesting ground-up approach as to how you might do this.

    There are questions on SO about this approach, should you want to write something yourself: Question on offline HTML5 database sync.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need to understand the working of this particular program, It seems to be
I need to understand how to use the generic Delphi 2009 TObjectList . My
I don't know if this is a right question, but i need to understand
I edited this question after i found a solution... i need to understand why
This is trivial, probably silly, but I need to understand what state cout is
I understand that using the facebook API I need an api key to connect,
I have a C++/MFC application I need to restructure. The app used to process
I have a basic question,there are two incidents happended while working with Tomcat. 1.I
If we are to separate our web server and app server, would we need
I get this error message while compiling: Assembly 'MyFramework [...]' uses 'System.Web.Extensions, Version=3.5.0.0 [...]'

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.