开发者

POST REST-Web-Service Call for iPhone application

Anyone have idea how to pass开发者_JS百科 value from iPhone application to the REST-Webservice using POST method.?

ex: http://mysite.com/services/updatescore/uid=1234&score=12658

I want to send this information using POST request. - How can I do it.?

Thanks.


I use ASIHTTPRequest

ASIFormDataRequest *request = [ASIFormDataRequest requestWithURL:url];
[request setPostValue:@"Ben" forKey:@"first_name"];
[request setPostValue:@"Copsey" forKey:@"last_name"];
[request setFile:@"/Users/ben/Desktop/ben.jpg" forKey:@"photo"];

See http://allseeing-i.com/ASIHTTPRequest/How-to-use for more info

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜