What's the locale code for traditional Chinese and French Canadian to be used for iPhone localizable strings file. I know the code for simplified Chinese and French, which is zh and fr, but not its counterpart.
+3
A:
Set it on your device and execute
NSLog(@"localeIdentifier: %@", [[NSLocale currentLocale] localeIdentifier]);
Nikolai Ruhe
2009-07-09 21:23:48
A:
You can change your language in the iPhone Simulator (though 'Settings'). The following code will show the language code:
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
NSArray *languages = [defaults objectForKey:@"AppleLanguages"];
NSString *currentLanguage = [languages objectAtIndex:0];
NSLog(@"Current language: %@", currentLanguage);
eelco
2009-11-05 15:03:49
A:
After some experiments, I found out that the locale code used to name the localization strings file for Chinese are:
zh_hant (traditional)
zh_hans (simplified)
Boon
2009-11-05 22:42:29