lifemoveson
lifemoveson

Reputation: 1691

Parse serializeJSON file format in iphone

I am trying to parse JSON file generated from ColdFusion server in SerializeJSON format. Is there any specific way to parse the JSON file. It is different than normal Twitter Feed JSON file. How to parse the JSON file in such a format ? I am using SBJSON File for parsing this.

{
"COLUMNS": [
    "ID",
    "TITLE",
    "CLASS_START",
    "CLASS_END",
  ],
"DATA": [
    [
        "7f9f3601",
        "Test                                                                                                                                                                                                                                                      ",
        "October, 25 2011 00:00:00",
        "October, 25 2011 00:00:00",

    ],
    [
        "5500a26b",
        "ABC                                                                                                                                                                                                                                        ",
        "October, 26 2011 14:47:00",
        "October, 27 2011 14:47:00",

    ]
]
}

Upvotes: 0

Views: 395

Answers (2)

Tim Dean
Tim Dean

Reputation: 8292

From the looks of it your server is returning an XML response with an embedded string, rather than returning JSON. You probably need to parse the XML you receive and pull out the contents of the element. Then you can take the contents of that element and try to parse it.

Upvotes: 1

Hot Licks
Hot Licks

Reputation: 47729

Well, you'd feed it into a JSON parser such as SBJSON.

Upvotes: 0

Related Questions