How to Localize Push Notification Permisssion Dial

2019-02-12 17:04发布

问题:

I am trying from the last 3 hours but not able to find any method to localize it. I am using iOS 10.0 means UNUserNotificationCenter. I want to localize it in Spanish-Mexico(es-MX) Language.

Please help.

回答1:

The only post I have found is Customizing the iOS permission dialog for push notifications Unfortunately, it is not possible to change the text / localisation of the message.



回答2:

You can change the messages for location permission, camera usage description, photo library usage description etc by adding a new file InfoPlist.strings and add strings for supported languages against keys NS*UsageDescription in the above file.



回答3:

You need to add the following lines into Info.plist:

<key>CFBundleDevelopmentRegion</key>
<string>en,ru</string>    

Value must contain at least two languages (it doesn't matter which ones).