Best way to have an app do user authentication, load/save online data?

Discussion in 'iOS Programming' started by CaptSaltyJack, Jun 29, 2009.

  1. CaptSaltyJack macrumors 6502

    Jun 28, 2007
    Obviously the cheapest way is to have a web server running on a host, and your iPhone app can use that. But I was wondering, if I wanted to build an iPhone app where a user could create an account & password, log in to authenticate, and send/retrieve data to/from the web site... is there any specialized API for that? I mean, should I use POST/GET requests? XML? JSON? What works best with the Cocoa Touch API?
  2. CaptSaltyJack thread starter macrumors 6502

    Jun 28, 2007
    After some research, it seems the best way is to send normal HTTP POST requests to a URL, and fetch the results as XML and use NSXMLParser to parse the results. Is this the best way, or is there an even better way to have an iPhone app interact with an HTTP server for user authentication, saving data, etc?
  3. sergio27 macrumors member

    Nov 2, 2008
    I apologize for not answering before. I use normal HTTP POSTs as well, and I chose to use my own format to write and parse the data because I didn't like the NSXMLParser.

Share This Page