0

I'm making POST Request from my iOS application and its getting back the Response but excluded from it some nodes. I've tried the same POST Request and from Wizdler (Chrome Extension) and the full response is received correctly without any missing nodes. I'm using AFNetworking Library to make the http post request.

code

Request and Response from XCode

enter image description here

The "country" node is retrieved in the iOS request but it's retrieved normally in requests from other tools. What could make such a problem ?

user1673892
  • 409
  • 2
  • 5
  • 17
  • I suspect an issue with `XMLReader` - this project hasn't been updated for years. Did you step through that code to see what happens when you call `dictionaryForXMLData` ? – koen Mar 28 '18 at 14:27
  • 1
    Also, please don't post screenshots here, but post your code directly - this is easier to read and the info won't be lost if the link to the pictures becomes invalid. Thanks. – koen Mar 28 '18 at 14:41
  • I've followed the XMLReader and printed the raw data from within there but it still does not contain the data of country node. – user1673892 Mar 28 '18 at 14:51
  • Please accept my apologies for this but i have a problem with copy and paste functionality right now and rewriting the code would consume a lot of time. – user1673892 Mar 28 '18 at 14:52
  • What is `qSearch` ? You use that to insert into `` in `[req setHTTPBody: ...]` – koen Mar 28 '18 at 15:03
  • Its query string returned from text box – user1673892 Mar 28 '18 at 15:08

1 Answers1

0

I've discovered that changing the header of my http request of Content-Type="text/xml" to "text/plain" solves the problem. But I'm still looking for justification of why this may have solved the issue.

user1673892
  • 409
  • 2
  • 5
  • 17