iOS: bundle name, bundle display name, bundle identifier...
當你創建一個project時,會要求你輸入product name & company identifier,這兩個property的值should和你在apple developer member center的“Provisioning Portal”的“App IDs"里創建的bundle identifier (NOT App ID)匹配!如果不匹配的話,push notification feature和cloud feature則不成功!!
例如,
當你創建的App ID時,設置的"Bundle Seed ID (App ID Prefix)"為"ABX453B", "Bundle Identifier (App ID Suffix)"為"edu.cityu.MobileCap",那么你的App ID為"ABX453B.edu.cityu.MobileCap"。
那么你創建project時,"company identifier"應該設置為"edu.cityu",product name應該設置為"MobileCap",也就是說?
company identifier的值 + product name的值 = bundle identifier in App ID
1. select project root node in the left navigation panel,在其旁邊出現的panel里選擇 "Targets" item。這時其旁邊就會出現屬性設置窗口
你會看到"Summary tab"的"bundle identifier",它只可以修改前半部分,即你之前創建project時設置的"edu.cityu“部分,而后面的product name部分無法修改。因此我們不能在這個地方修改它,而要select "info" tab,見
你會看到"bundle identifier"的值為 edu.cityu.${PRODUCT_NAME: XXXX),原來是用了動態參數,難怪上面提到的bundle identifier只能修改一部分。而在這里則可以全部修改,例如我把它改為”edu.cityu.testApp"。
注意:你的app project的這個"bundle identifier"值必須和你之前創建的App ID的"bundle identifier"匹配
你還能看到"Bundle Name" and "Bundle display name"都設置為動態參數${PRODUCT_NAME}。
Bundle name - is folder name, where your app (including executable file and all resources) will be stored (Cool Program.app)。建議不要修改bundle name
Bundle display name - is what will be shown on iPhone screen,即當你安裝該app到iPhone上顯示的name。
注意:Bundle Display name must correspond to Bundle name,即bundle display name和bundle name不能相差太遠。例如bundle name設置為 TheApplication, 而 bundle display name設置為“金瓶梅”,則apple會拒絕你的app。
當然,你也可以在info.plist file里修改這些屬性。
總結
以上是生活随笔為你收集整理的iOS: bundle name, bundle display name, bundle identifier...的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 绝地求生亚服手机版
- 下一篇: 定制iOS 7中的导航栏和状态栏