• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Checking availability of host/website
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Checking availability of host/website


  • Subject: Re: Checking availability of host/website
  • From: Omar Qazi <email@hidden>
  • Date: Sat, 28 Jun 2008 00:58:03 -0700


On Jun 28, 2008, at 12:36 AM, Michael Kaye wrote:

I have implemented an SCNetworkReachAbility based method to test firstly whether a network is available, but I was wondering in your opinion what is the best way to check that the remote host/website is responding to requests?


It depends on what your definition of availability is. If you want to ping the server you can wrap a ping command through NSTask. If you want to check if it responds to connections, NSURLConnection is for you. If you want to check if the system is connected to the internet you would use the api for that.

You probably just want to open an NSURLConnection and see if it doesn't accept the connection within a second or whatever.

Omar Qazi
Hello, Galaxy!
1.310.294.1593

Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Checking availability of host/website (From: Michael Kaye <email@hidden>)

  • Prev by Date: [Job] Develop at Skype
  • Next by Date: Re: How to deal with a MenuItem with both a binded state property and an action method
  • Previous by thread: Checking availability of host/website
  • Next by thread: [Job] Develop at Skype
  • Index(es):
    • Date
    • Thread