iOS - 应用程序图标支持带有不同支持iOS版本的Phonegap Build Project的错误

问题描述 投票:2回答:2

我在发布通过Phonegap Build生成的.ipa文件时遇到问题但是我从Application Loader收到以下消息:

“缺少必需的ico文件......该软件包不包含Iphone的应用程序图标... 120 x 120像素格式的ios版本> = 7”“

我哪里错了?

按照上面的config.xml

<icon src="ic_launcher.png" />
<icon height="72" src="ic_launcher.png" width="72" />
<icon height="48" src="ic_launcher.png" width="48" />
<icon height="36" src="ic_launcher.png" width="36" />
<content src="index.html" />
<preference name="permissions" value="none" />
<preference name="orientation" value="portrait" />
<preference name="target-device" value="universal" />
<preference name="fullscreen" value="false" />
<preference name="webviewbounce" value="true" />
<preference name="prerendered-icon" value="true" />
<preference name="stay-in-webview" value="false" />
<preference name="ios-statusbarstyle" value="black-opaque" />
<preference name="StatusBarOverlaysWebView" value="false"/>
<preference name="StatusBarBackgroundColor" value="#000000"/>
<preference name="StatusBarStyle" value="blackopaque" />
<preference name="detect-data-types" value="true" />
<preference name="exit-on-suspend" value="false" />
<preference name="disable-cursor" value="false" />
<preference name="android-minSdkVersion" value="14" />
<preference name="android-installLocation" value="auto" />
<plugin name="org.apache.cordova.battery-status" />
<plugin name="cordova-plugin-camera" source="npm" />
<plugin name="org.apache.cordova.media-capture" />
<plugin name="org.apache.cordova.console" />
<plugin name="org.apache.cordova.contacts" />
<plugin name="org.apache.cordova.device" />
<plugin name="org.apache.cordova.device-motion" />
<plugin name="org.apache.cordova.device-orientation" />
<plugin name="org.apache.cordova.dialogs" />
<plugin name="org.apache.cordova.file" />
<plugin name="org.apache.cordova.file-transfer" />
<plugin name="org.apache.cordova.geolocation" />
<plugin name="org.apache.cordova.globalization" />
<plugin name="org.apache.cordova.inappbrowser" />
<plugin name="org.apache.cordova.media" />
<plugin name="org.apache.cordova.network-information" />
<plugin name="org.apache.cordova.vibration" />    
<plugin name="cordova-plugin-whitelist" version="1" />
<plugin name="cordova.plugins.diagnostic" spec="~3.1.5" />
<platform name="ios">
    <!-- iPhone 6 / 6+ -->
    <icon src="[email protected]" platform="ios" width="180" height="180" />
    <!-- iPhone / iPod Touch  -->
    <icon src="icon-60.png" platform="ios" width="60" height="60" />
    <icon src="[email protected]" platform="ios" width="120" height="120" />
    <icon src="[email protected]" platform="ios" width="120" height="120" />
    <icon src="[email protected]" platform="ios" width="120" height="120" />
    <icon src="[email protected]" platform="ios" width="120" height="120" />
    <!-- iPad -->
    <icon src="icon-76.png" platform="ios" width="76" height="76" />
    <icon src="[email protected]" platform="ios" width="152" height="152" />
    <icon src="[email protected]" platform="ios" width="167" height="167" />
    <!-- Settings Icon -->
    <icon src="icon-small.png" platform="ios" width="29" height="29" />
    <icon src="[email protected]" platform="ios" width="58" height="58" />
    <icon src="[email protected]" platform="ios" width="87" height="87" />
    <!-- Spotlight Icon -->
    <icon src="icon-40.png" platform="ios" width="40" height="40" />
    <icon src="[email protected]" platform="ios" width="80" height="80" />
    <icon src="[email protected]" platform="ios" width="120" height="120" />
</platform>
<access origin="*" />
<access origin="*://*.googleapis.com/*" subdomains="true" />
<access origin="*.google.com" />
<access origin="*.googleapis.com" />
<access origin="*.gstatic.com" />
<access origin="*.googleusercontent.com" />
<access origin="google.com" subdomains="true" />
<access origin="googleapis.com" subdomains="true" />
<access origin="gstatic.com" subdomains="true" />
<access origin="googleusercontent.com" subdomains="true" />
<access origin="http://127.0.0.1*" />
<access origin="https://example.com" />
<access origin="https://example.com" subdomains="true" />
<access origin=".*" />
<allow-intent href="http://*/*" />
<allow-intent href="https://*/*" />
<allow-intent href="tel:*" />
<allow-intent href="sms:*" />
<allow-intent href="mailto:*" />
<allow-intent href="geo:*" />
<platform name="android">
    <allow-intent href="market:*" />
</platform>
<platform name="ios">
    <allow-intent href="itms:*" />
    <allow-intent href="itms-apps:*" />
</platform>

ios cordova build icons application-loader
2个回答
1
投票

您可能没有为所有OS版本添加图标文件(项目支持)。

Here是各种尺寸图标的详细信息,您应该添加。

所需图标大小列表(考虑支持iPad,iPod,iPhone,手表,iTune,聚光灯或CarPlay等不同设备)

Icon-Small.png - 29x29 
[email protected] - 58x58 
[email protected] - 87x87 
Icon-40.png - 40x40 
[email protected] - 80x80 
[email protected] - 120x120 
[email protected] - 120x120 
[email protected] - 180x180 
Icon-76.png - 76x76 
[email protected] - 152x152 
Icon-120.png - 120x120

0
投票

我能够解决问题。按照以下解决方案

    <platform name="ios">
    <icon height="57"  platform="ios"  src="icon.png"           width="57" />
    <icon height="114" platform="ios"  src="icon-2x.png"        width="114" />
    <icon height="40"  platform="ios"  src="icon-40.png"        width="40" />
    <icon height="80"  platform="ios"  src="icon-40-2x.png"     width="80" />
    <icon height="50"  platform="ios"  src="icon-50.png"        width="50" />
    <icon height="100" platform="ios"  src="icon-50-2x.png"     width="100" />
    <icon height="60"  platform="ios"  src="icon-60.png"        width="60" />
    <icon height="120" platform="ios"  src="icon-60-2x.png"     width="120" />
    <icon height="180" platform="ios"  src="icon-60-3x.png"     width="180" />
    <icon height="72"  platform="ios"  src="icon-72.png"        width="72" />
    <icon height="144" platform="ios"  src="icon-72-2x.png"     width="144" />
    <icon height="76"  platform="ios"  src="icon-76.png"        width="76" />
    <icon height="152" platform="ios"  src="icon-76-2x.png"     width="152" />
    <icon height="29"  platform="ios"  src="icon-small.png"     width="29" />
    <icon height="58"  platform="ios"  src="icon-small-2x.png"  width="58" />
</platform>
© www.soinside.com 2019 - 2024. All rights reserved.