I’m trying to implement the in App purchase mechanism in my iPhone app. To do so I need to make a json object out of the receipt string on my rails server, and send it to a iTunes server.
- How can I create a json object out of a string? to_json didn’t work for me…
- How can I send that json object to the specified Server and wait for the request…
Thanks
Maechi
You asked: How can I create a json object out of a string?
Is your string already in json format? If so, just send it along.
You’d use to_json when you have an object that you want to auto-turn into json. Example:
Will output: {“whatever”:”oh hai”,”whatever_x_two”:”good day”}