我有問題有關YAJLiOS解析器...... 我有下一個JSON數據:YAJLiOS無法解析非英文字母?
{{
body = "Привет";
mid = 3;
"read_state" = 1;
}
{ body = "hi";
mid = 3;
"read_state" = 1;
}}
,我試圖讓「身體」,結果是:「\ U0416 \ U0412」和「喜」
它可能是與編碼的問題,但我不知道如何解決它
感謝您的時間!
你可以顯示你正在做解析的代碼嗎? – jonkroll 2012-03-29 15:30:02
sure: NSString * getFriendDialogs = [NSString stringWithFormat:@「https://api.vk.com/method/messages.getHistory?access_token=%@&uid=%@&chat_id=uid&count=10」,currentAccessToken,UidOfSelectedFriend] ; NSURL * url = [NSURL URLWithString:getFriendDialogs]; NSURLRequest * requestObj = [NSURLRequest requestWithURL:url]; NSData * tempContainer = [NSURLConnection sendSynchronousRequest:requestObj returningResponse:nil error:nil]; NSDictionary * dialogsDictionary = [tempContainer yajl_JSON]; idString = [dialogsDictionary valueForKey:@「body」]; – ignotusverum 2012-03-29 15:34:01