2

I have read the previous stackoverflow posts as well as Apple documentation on this matter, trie countless attempts, and none localizes the name under icon name on ios on my ionic apps on xcode 7.3.

Here is the minimum steps example:

$ ionic start foobar
$ edit config.xml to foobar
$ ionic build

In xcode 7.3
Menu->Editor-> Export Localizations
Edit the generated file to a french translation, and imported again
Remove Display Bundle Name from Info.plist
Set the simulator to French

Whatever the values I set on CFBundleDisplayName or CFBundleName, it always displays: foobar.

Here are some screenshots:

enter image description here

enter image description here

enter image description here

elp
  • 8,021
  • 7
  • 61
  • 120
Code Rage
  • 555
  • 3
  • 9

2 Answers2

3

OK, the name of .strings file should always be 'InfoPlist.strings', please try to rename it. It's not about the xcode version and it's ok to add CFBundleDisplayName key in info.plist file

Gary Lip
  • 336
  • 2
  • 6
  • I tried that, it didn't work. The filename is generated automatically by XCode 7.3 import settings. After I rename the filename, it didn't recognized the files. – Code Rage Apr 18 '16 at 09:10
  • You can create one your self, see this link http://blog.hsin.tw/2015/ios-dev-localize-info-plist-infoplist-strings/ you can just follow it by the images if you don't understand chinese – Gary Lip Apr 18 '16 at 09:16
  • Looks great, actually what I'm trying to achieve is to support a different in Display Bundle Name in Chinese-Taiwan, I use French because it's simple for testing. But it doesn't work. When I press localize it doesn't shows 'Base', only English. – Code Rage Apr 18 '16 at 09:37
  • No. It's not working. The post looks great, but it doesn't working on a ionic app in xcode 7.3, like none of other stackoverflow posts work. 1. The base doesn't shows. 2. If I create that file it doesn't compile. – Code Rage Apr 18 '16 at 10:09
  • InfoPlist.strings is the way to go. Best to add it fresh, with File -> New -> File -> Resource -> String File. Then fill this in:
    `"CFBundleDisplayName" = "localized name here"; "CFBundleName" = "and here the same, but less than 16 characters";`
    – Pierre Aug 23 '16 at 09:49
0

Can you try to insert this in info.plist

<key>CFBundleDisplayName</key>
<string>${PRODUCT_NAME}</string>

Here is the reference from iOS development library and search for CFBundleDisplayName https://developer.apple.com/library/ios/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html#//apple_ref/doc/uid/20001431-110725

Gary Lip
  • 336
  • 2
  • 6
  • That was originally on info.plist, I removed it according to another stackoverflow post. And also doesn't work. The information provided on your link doesn't work. – Code Rage Apr 18 '16 at 07:54
  • Here is the link that instructs to remove it: http://stackoverflow.com/questions/30298548/could-not-localize-ios-app-bundle-display-name I tested that project and it works, however replicating the same steps on my ionic project doesn't work. As I mention on my post, I read the Apple developers documentation, all pages regarding this issue, and tried all solutions, nothing works on xcode 7.3. – Code Rage Apr 18 '16 at 07:59
  • This is an ionic app, the build is based on cordova. I followed step by step the link you sent, and when I press localize, it simple sets to English. It doesn't display a dialog asking for 'Base' or 'English' as it's mention on the post. – Code Rage Apr 18 '16 at 09:40
  • Not only doesn't work, if I add that file, it compilation fails as well. – Code Rage Apr 18 '16 at 09:46