0

Can anyone tell me how to send a file to server and a username. I tried to set HTTP body with the content of the file and use GET method to set username but it doesn't work and encounter the exact situation as this post:( this is a bug) :

NSURLRequest cannot handle HTTP body when method is not POST? As the post says, can anyone show me how to use PUT method as in both the ios client and php server or show me another method ?

Community
  • 1
  • 1
Victor Pham
  • 53
  • 12
  • related: http://stackoverflow.com/q/978061/643383 – Caleb May 17 '13 at 21:14
  • This all depends on the webservice you are calling. Is it expecting a GET or POST or PUT request? – Tim May 18 '13 at 00:07
  • Actually I am trying to send a xml to the server together with the username, which is the best way to it? Can anyone show me some sample code for both server (php) and ios client – Victor Pham May 18 '13 at 13:47

0 Answers0