ios7 - Post smiley with text usingAFnetworking -
I am using AFNetworking 2.0 in my iOS application. It is working fine at each level. I was stuck in a problem how to update the situation using Afnetworking to post the smiley with the text. Please help me if nobody does this.
"\ ud83d \ ude04" Sequence for JSON Unicode Escape U + D 83 DU + D004 , Which is a "surrogate pair" for Unicode U + 1F 604 (face smiling with mouth and smile).
But NSJSANASialisation decodes it properly, as can be seen in the following example:
const char * jsonString = "{\" emoji \ ": "\\ ud83d \\ ude04 \"}; NSLog (@ "JSON:% s", jsonString); NSDTA * JSNDTTA = [NSDATA DATAVITABITS: JasonString Length: Stellen (JasonString)]; NSError * error; NSDictionary * jsonDict = [NSJSNRialization JSONObjectWithData: jsonData Option: 0 Error: & amp; Error]; Self.myLabel.text = [jsonDict objectForca: @ "emoji"]; NSLog (@ "emoji:% @", self. Mileage text); Output: JSON: {"emoji": "\ ud83d \ ude04"} Emoji: ð ??? ???
Comments
Post a Comment