NSMutableDictionary使用重音词返回不正确的值

时间:2012-11-09 00:52:36

标签: objective-c

我正在尝试从xml获取字符串  NSData * xmlData = [request responseData];

NSString *stringData = [[NSString alloc] initWithData:xmlData encoding:NSUTF8StringEncoding];

loginParsingDelegate *loginResultParser = [[loginParsingDelegate alloc] init];
NSXMLParser *parser = [[NSXMLParser alloc] initWithData:xmlData];
[parser setDelegate:loginResultParser];
[parser parse];

 NSString *filePath = [NSString stringWithFormat:@"%@/conf.plist", DOCUMENTS_FOLDER] ;
NSMutableDictionary* plistDict = [[NSMutableDictionary alloc] init];
   NSString *city = [parsingResult objectForKey:@"city"];

但是当有口音时,这就错了......例如:   圣保罗=“圣保罗”,但圣保罗我得到“圣保罗”

怎么了? xml返回正确...

0 个答案:

没有答案