如何在IOS中执行基本的http

问题描述:

我想结合一个基本的HTTP协议,以便为我的iPad应用程序的用户与后端数据库进行同步。我不打算流式传输音频或视频,我只想访问服务器并执行少量的HTTP Gets和Puts。除了流之外,我没有看到IOS对HTTP的任何支持。

I want to incorporate a basic HTTP protocol to allow syncing with a back-end database for the users of my iPad app. I don't intend to stream audio or video, I just want to access a server and do some low volume HTTP Gets and Puts. I don't see any IOS support for HTTP other than streaming.

当然,您可以将HTTP用于XML,JSON服务,等等。请参见 NSURLConnection http://developer.apple.com/library/ios/#documentation/Cocoa/Reference/Foundation/Classes/NSURLConnection_Class/Reference/Reference.html

Certainly you can use HTTP for XML, JSON services, etc. Look at NSURLConnection http://developer.apple.com/library/ios/#documentation/Cocoa/Reference/Foundation/Classes/NSURLConnection_Class/Reference/Reference.html