tags:

views:

70

answers:

3

Hi, we were asked to develop an iphone app like the one in the figure. The problem is: we have no experience in IOS development.

alt text

For the basic part I can handle the learning curve, but i need suggestions, best practices on the UIKit model and controls.

This is a newspaper app. The accordion control shows/hides content based on categories retrieved by an ASP .NET CMS on which we have no control.

I can suggest to the CMS holder to develop a couple of web services (WCF) but i'm not sure how to interface iOS with MS technology. Furthermore, i have the idea that simple aspx that returns XML/JSON data will be easier to call, and support, but slightly less secure.

So, suggestions? Tutorials?

+1  A: 

You want to output an XML feed in "plist" format (look it up, its simple theres lots of info on it).

Then you can do:

NSArray *plistContents = [NSArray arrayWithContentsOfURL:[NSURL URLWithString:@"http://theinternet.com/pathToMyPlist.asp"]];

That will get all the output into an array.

Some other resources you may find interesting/useful include NSURLRequest and NSURLConnection. For the latter you will have to learn about delegate methods and such - its complicated, but its incredibly useful information.

Thomas Clayson
+1  A: 

We did several applications here using XML parsing like what you're suggesting at the end of your question. If you are concerned about security, you can implement handshaking or other security measures over that.

EDIT: XML parsing done using NSURLConnection to gather the content and NSXMLParser/NSXMLParserDelegate to do the actual parsing.

EDIT2: There is an official sample, called SeismicXML from Apple. It should get you started with iPhone XML parsing and data downloading.

jv42
+1  A: 

If you like to use JSON and a very good HTTP-request-framework I have two links for you. Both sites contain various tutorials on how to use them.

  1. json-framework
  2. ASIHTTPRequest

Concerning the request and delegate stuff: For a start, I would skip the delegate part and use a synchronized HTTP request called in a thread (you'll see what that is on the second website). That makes the response handling a lot easier for the start. But I personally think, that using an asynchronous request is not a must. It's just nicer, if the architecture allows it. In my application, it wasn't realizable without lots of code overhead.

Sebastian Wramba