iOS App – Film Blog (Part 4)

So I need to test for an internet connection to make sure that I can download the JSON file with all the Film Reviews in it.

http://developer.apple.com/library/ios/#samplecode/Reachability/Introduction/Intro.html

https://github.com/tonymillion/Reachability

http://iosameer.blogspot.co.uk/2013/01/checking-internet-connection-in-ios-apps.html

Got it working using the last link, just as a quick test, will amend further.

Added Reachability.h/.m and added the SystemConfiguration.framework (this actually added to the correct folder!)

Reachability was made in 2010 so isn’t ARC complient.

Go to Targets -> Build Phases -> Compile Sources and add

-fno-objc-arc

Advertisements
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: