storing data on a server from an app

佐手、 提交于 2019-12-03 21:52:48

Have a look at NSUrlConnection. Using it you can synchronously & asynchronously transmit data to your server using a POST request.

Check out ASIHTTPRequest. It can GET/POST from a URL asynchronously and for storage, if the data set is small enough look at NSUserDefaults.

On the server side (if the scripts are PHP), you can handle the data in the $_POST and $_GET variables just as if they were populated from the web.

If you wanted you could post the variables individually in their own $_POST or $_GET variables, or as 1 JSON string which you could decode when you receive it.

You may also want to check out RestKit which will make things easier when dealing with downloading/uploading/processing JSON.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!