开发者

Is it possible to send database query within a NSUrl request?

i am developing iphone application which connects to a php page using NSUrl request.The php page on the server side ,in turn,connects to the database (mysql) to perform transactions.Till now i was passing only parameters to the actual query on php page which was working fine.But when sending query from iphone end through NSUrl ,either connection fails or the query is assigned a nil value.开发者_Go百科Is there any way to send query using NSUrl or some othr method?


It sounds like you have a working server-side script that returns data in response to well-formed requests, so it's a matter of getting your NSURLConnection to make requests in the appropriate fashion. If you have a known-good request, you can inspect on the properties of the NSURLRequest object you're creating (HTTPBody, URL, etc.) and see where you're going wrong. Also pay attention to any error messages you might be receiving in your delegate methods (i.e., connection:didFailWithError:)

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜