Converting NSArray -> JSON -> NSData -> PHP server ->JSON representation

后端 未结 3 1655
谎友^
谎友^ 2020-12-05 08:47

I am converting an Array of NSDictionaries to JSON data with the following...

Create my data...

NSMutableArray *arrayOfDicts = [[NSMutableArray alloc         


        
3条回答
  •  南方客
    南方客 (楼主)
    2020-12-05 09:03

    You can't send it this way. NSJSONSerialization is for iOS use. It is basically a plist. You will need a way to decode it on PHP and I doubt it exists. Instead, you need to send a JSON string. I am not sure what you mean by "leaves quotes around titles." What are they doing there in the first place? Can you verify your original JSON string here?

提交回复
热议问题