Re: [PHP] Checking for internet connection.

2009-12-23 Thread Kim Madsen
Kim Madsen wrote on 23/12/2009 17:01: Okay, explanation excepted, E-mails can easily be misunderstood :-) May you have a merry Christmas (grab another cup of choco, just in case ;-)) correction: accepted Now _I'M_ gonna get a cup of chocolate :-) -- Kind regards Kim Emax - masterminds.dk --

Re: [PHP] Checking for internet connection.

2009-12-23 Thread Kim Madsen
Bob McConnell wrote on 23/12/2009 15:55: > The problem arises when too many of the relevant parts are also removed, > which happened far too often on this thread as well as others. When the > core context is not retained, the conversation drifts and quickly > becomes useless to either the early p

Re: [PHP] Checking for internet connection.

2009-12-23 Thread Daniel Egeberg
On Wed, Dec 23, 2009 at 14:35, Bob McConnell wrote: > I don't keep copies of every message in any of the > dozens of mailing lists and news groups I follow, so there is no simple > way to go back through the conversation to figure out where it all came > from. Fortunately, other people keep compl

RE: [PHP] Checking for internet connection.

2009-12-23 Thread Bob McConnell
From: Kim Madsen > Bob McConnell wrote on 23/12/2009 14:35: >> From: Andy Shellam >> And I was pointing out that this would not be a valid test when there is a caching DNS on the LAN. >> >>> I also pointed out how to avoid caching issues - the >>> comment was aimed at the author of the

Re: [PHP] Checking for internet connection.

2009-12-23 Thread Kim Madsen
Hi Bob Bob McConnell wrote on 23/12/2009 14:35: From: Andy Shellam And I was pointing out that this would not be a valid test when there is a caching DNS on the LAN. I also pointed out how to avoid caching issues - the comment was aimed at the author of the message before mine. Too much o

RE: [PHP] Checking for internet connection.

2009-12-23 Thread Bob McConnell
From: Andy Shellam >> And I was pointing out that this would not be a valid >> test when there is a caching DNS on the LAN. > I also pointed out how to avoid caching issues - the > comment was aimed at the author of the message before mine. > >> Too much of the conversation and most of the attri

Re: [PHP] Checking for internet connection.

2009-12-22 Thread Andy Shellam
> > And I was pointing out that this would not be a valid test when there is > a caching DNS on the LAN. I also pointed out how to avoid caching issues - the comment was aimed at the author of the message before mine. > > Too much of the conversation and most of the attribution was stripped >

RE: [PHP] Checking for internet connection.

2009-12-22 Thread Bob McConnell
From: Andy Shellam >> >> I'm confused... what's the problem with just trying to hit >> the update server? If you can then you check for updates, if >> not then you, erm, don't. Simples, no? > > True, I think I said this same thing in a previous post - I > suggested the DNS option if all the OP wa

Re: [PHP] Checking for internet connection.

2009-12-22 Thread Andy Shellam
> > I'm confused... what's the problem with just trying to hit the update server? > If you can then you check for updates, if not then you, erm, don't. Simples, > no? True, I think I said this same thing in a previous post - I suggested the DNS option if all the OP wanted to do was check if a

Re: [PHP] Checking for internet connection.

2009-12-22 Thread Kim Madsen
Bob McConnell wrote on 21/12/2009 15:05: Both at home and at work there are caching DNS on the LAN. So a DNS request may come back with a valid IP address when the WAN connection is down. I still won't be able to connect to the remote site. Then use fopen() to read a page you know exists? --

RE: [PHP] Checking for internet connection.

2009-12-22 Thread Ashley Sheridan
On Tue, 2009-12-22 at 08:27 -0500, Bob McConnell wrote: > From: Andy Shellam > > >> > >> Both at home and at work there are caching DNS on the LAN. So a DNS > >> request may come back with a valid IP address when the WAN connection > is > >> down. I still won't be able to connect to the remote s

RE: [PHP] Checking for internet connection.

2009-12-22 Thread Bob McConnell
From: Andy Shellam >> >> Both at home and at work there are caching DNS on the LAN. So a DNS >> request may come back with a valid IP address when the WAN connection is >> down. I still won't be able to connect to the remote site. > > Dig an external server - e.g. dig @a.root-servers.net google.

Re: [PHP] Checking for internet connection.

2009-12-22 Thread Stuart Dallas
On 21 Dec 2009, at 19:40, Andy Shellam wrote: >> >> Both at home and at work there are caching DNS on the LAN. So a DNS >> request may come back with a valid IP address when the WAN connection is >> down. I still won't be able to connect to the remote site. > > Dig an external server - e.g. dig

Re: [PHP] Checking for internet connection.

2009-12-22 Thread Andy Shellam
> > Both at home and at work there are caching DNS on the LAN. So a DNS > request may come back with a valid IP address when the WAN connection is > down. I still won't be able to connect to the remote site. Dig an external server - e.g. dig @a.root-servers.net google.co.uk If your net is down t

Re: [PHP] Checking for internet connection.

2009-12-22 Thread Daniel Brown
On Sat, Dec 19, 2009 at 19:13, Angus Mann wrote: > Hi all. > > I'w writing a PHP app that is designed to run over a LAN, so internet > connection for the server is not really essential. Some users may > deliberately not connect it to the internet as a security precaution. > > But I'd like the app

RE: [PHP] Checking for internet connection.

2009-12-21 Thread Bob McConnell
From: Andy Shellam >> By attempting to connect you will implicitly query DNS (which itself >> is a connection to server). > > No it's not - it's putting out a packet targeted at an IP address > and hoping a server will answer - hence why multi-cast works for > DNS because you're not directly co

Re: [PHP] Checking for internet connection.

2009-12-20 Thread Andy Shellam
> By attempting to connect you will implicitly query DNS (which itself > is a connection to server). No it's not - it's putting out a packet targeted at an IP address and hoping a server will answer - hence why multi-cast works for DNS because you're not directly connecting to a specified ser

Re: [PHP] Checking for internet connection.

2009-12-20 Thread LinuxManMikeC
On Sun, Dec 20, 2009 at 2:32 AM, Andy Shellam wrote: >> >> I think the only way to detect if it can connect to the Internet is to >> see if you can grab a file from somewhere on the Internet. I'd hazard a >> guess that when operating systems are able to tell you they can "connect >> to the Interne

Re: [PHP] Checking for internet connection.

2009-12-20 Thread Andy Shellam
> > I think the only way to detect if it can connect to the Internet is to > see if you can grab a file from somewhere on the Internet. I'd hazard a > guess that when operating systems are able to tell you they can "connect > to the Internet" they are actually saying they can ping a predetermined

Re: [PHP] Checking for internet connection.

2009-12-19 Thread Phpster
The next way to handle this might be to code an AIR app. Then it's a simple js trap to see if connectivity exists. Bastien Sent from my iPod On Dec 19, 2009, at 7:13 PM, "Angus Mann" wrote: Hi all. I'w writing a PHP app that is designed to run over a LAN, so internet connection for the

Re: [PHP] Checking for internet connection.

2009-12-19 Thread John Corry
Curl_init() will return a resource or false if it fails, like it would if no Internet connection were present. J Corry Sent from my iPhone On Dec 19, 2009, at 5:36 PM, "Angus Mann" wrote: Why can't you put the update on the same LAN server that the app resides? If that is not possible,

Re: [PHP] Checking for internet connection.

2009-12-19 Thread Ashley Sheridan
On Sun, 2009-12-20 at 10:36 +1000, Angus Mann wrote: > Why can't you put the update on the same LAN server that the app resides? > > If that is not possible, what about using CURL, and update if it can connect > successfully, but don't if it cannot? > > Thanks, > Ash > http://

Re: [PHP] Checking for internet connection.

2009-12-19 Thread Angus Mann
Why can't you put the update on the same LAN server that the app resides? If that is not possible, what about using CURL, and update if it can connect successfully, but don't if it cannot? Thanks, Ash http://www.ashleysheridan.co.uk Since the LAN is remote (many hundred

Re: [PHP] Checking for internet connection.

2009-12-19 Thread Ashley Sheridan
On Sun, 2009-12-20 at 10:13 +1000, Angus Mann wrote: > Hi all. > > I'w writing a PHP app that is designed to run over a LAN, so internet > connection for the server is not really essential. Some users may > deliberately not connect it to the internet as a security precaution. > > But I'd like

Re: [PHP] checking for internet connection

2005-07-21 Thread Richard Lynch
On Wed, July 20, 2005 12:49 am, Steven said: > I am looking for a simple way to check if the server is connected to the > Internet, they use a dialup to get Internet connection, and I need to > email reports out, but want to check to see if the user remembered to > connect to the Internet first. I

Re: [PHP] checking for internet connection

2005-07-20 Thread James
Assuming they connect to check their email every now and then, you do realize people will still receive your email regardless of whether their connection is up or not? The emails reside on the email server until the user retrieves them. - Original Message - From: "Steven" <[EMAIL PROT