I've tried:
changing the file at myapp/platforms/android/res/drawable/icon.png
editing the tag in www/config.xml
minor sacrifices
thanks!
If you have correctly updated your icon files in platforms/ios/YourAppName/Resources/icons and you still can't see the change then make sure you:
Completely remove the app from your device
In Xcode go to Product > Clean and then re run your app.
You need to replace all icon files in res folder.
Once you done, just clean your eclipse project and run.
although you accepted a different answer, that did not help me so for some of you reading this please note the following:
the accepted answer will work most probably only if u build ur
app locally
u do not need to overwrite the default platform icons
... phonegap lets you overwrite everything from the config.xmlfile
you need to use something like this in you config.xml:
<icon src="icon.png" />
<icon gap:platform="android" gap:qualifier="ldpi" src="img/icons/android/icon-36-ldpi.png" />
<icon gap:platform="android" gap:qualifier="mdpi" src="img/icons/android/icon-48-mdpi.png" />
<icon gap:platform="android" gap:qualifier="hdpi" src="img/icons/android/icon-72-hdpi.png" />
<icon gap:platform="android" gap:qualifier="xhdpi" src="img/icons/android/icon-96-xhdpi.png" />
<icon gap:platform="ios" height="57" src="img/icons/ios/icon-57.png" width="57" />
<icon gap:platform="ios" height="72" src="img/icons/ios/icon-72.png" width="72" />
<icon gap:platform="ios" height="114" src="img/icons/ios/icon-57-2x.png" width="114" />
<icon gap:platform="ios" height="144" src="img/icons/ios/icon-72-2x.png" width="144" />
<icon gap:platform="winphone" src="img/icons/windows-phone/icon-48.png" />
<icon gap:platform="winphone" gap:role="background" src="img/icons/windows-phone/icon-173-tile.png" />
please note that the path is img/bla-bla-bla ... it can be whatever
you want ... BUT ... that path it is relative to you www folder ...
so it will actually map to www/img/bla-bla-bla
hope this helps someone ... i found it the hard way :)
Rares
Related
I try to create apk file using phonegap service.
Here is my config.xml file in my project:
<?xml version='1.1' encoding='utf-8'?>
<widget id="il.co.geomind.gilgalplay" version="1.0.0" xmlns="http://www.w3.org/ns/widgets" xmlns:gap="http://phonegap.com/ns/1.0">
<name>sites</name>
<description>
app for sites mapping
</description>
<author email="jacklondon#ddd.com" href="">
</author>
<content src="index.html" />
<access origin="*" />
<preference name="Orientation" value="portrait" />
<preference name="permissions" value="none"/>
<feature name="http://api.phonegap.com/1.0/camera"/>
<feature name="http://api.phonegap.com/1.0/geolocation"/>
<icon src="images/icons/ldpi.png" gap:platform="android" gap:qualifier="ldpi" />
<icon src="images/icons/mdpi.png" gap:platform="android" gap:qualifier="mdpi" />
<icon src="images/icons/hdpi.png" gap:platform="android" gap:qualifier="hdpi" />
<icon src="images/icons/xhdpi.png" gap:platform="android" gap:qualifier="xhdpi" />
<icon src="images/icons/xxhdpi.png" gap:platform="android" gap:qualifier="xxhdpi" />
<icon src="images/icons/xxxhdpi.png" gap:platform="android" gap:qualifier="xxxhdpi" />
<!-- iPhone / iPod Touch -->
<icon src="images/icons/mdpi.png" gap:platform="ios" width="60" height="60" />
<icon src="images/icons/xhdpi.png" gap:platform="ios" width="120" height="120" />
<!-- Settings Icon -->
<icon src="images/icons/ldpi.png" gap:platform="ios" width="29" height="29" />
<icon src="images/icons/mdpi.png" gap:platform="ios" width="58" height="58" />
<!-- Spotlight Icon -->
<icon src="images/icons/ldpi.png" gap:platform="ios" width="40" height="40" />
<icon src="images/icons/mdpi.png" gap:platform="ios" width="80" height="80" />
<gap:platform name="android" />
<gap:splash src="images/icons/screen-xhdpi.png"/>
<gap:plugin name="cordova-plugin-whitelist" source="npm" />
<gap:plugin name="org.apache.cordova.camera" version="0.3.6" source="npm" />
<gap:plugin name="org.apache.cordova.device" version="0.3.0" source="npm"/>
<gap:plugin name="com.phonegap.plugins.pushplugin" version="2.5.0" source="npm"/>
<gap:plugin name="org.apache.cordova.geolocation" version="0.3.12" source="npm"/>
</widget>
I make zip file from the project and make upload to the phonegap service I get this error:
Error - The following plugin, plugin version or a dependancy of this plugin is not on npm: com.phonegap.plugins.pushplugin#2.5.0
Any idea why I get error above and how to fix it?
By setting the source to Node Package Manager (source="npm"), you're telling PhoneGap Build to retrieve the plugin from that location, but "com.phonegap.plugins.pushplugin, version 2.5.0" isn't actually there.
If we look on npmjs.com for the push plugin, there are two plugin search results but as mentioned in the other Answer, it hasn't been updated for over 2 years and is even labeled "-deprecated".
Assuming you want a push notification plugin, I recommend trying to find an official one. To do so, search for them by beginning with “cordova-plugin” coupled with whatever you’re looking for: "cordova-plugin-push". This led me to this one, which would probably work.
In your config.xml file, add a reference to it like so:
<plugin name="cordova-plugin-push-notification" version="2.5.2" source="npm" />
I used version 2.5.2 since that's the latest version:
For further reference, see my guide on using NPM with PhoneGap Build.
It looks like you are trying to use https://github.com/phonegap-build/PushPlugin, which appear to be deprecated and hasn't had a release in 2 years.
Looks like you should try https://github.com/phonegap/phonegap-plugin-push instead which is the replacement for it
I am working on an android app with phonegap. I have tried all sorts of stuff to get my icon on the app, but have been unsuccessful. The android bot icon appears on the app when installed from apk.
I have this in config.xml:
<icon density="ldpi" src="www/res/icon/android/ldpi.png" />
<icon density="mdpi" src="www/res/icon/android/mdpi.png" />
<icon density="hdpi" src="www/res/icon/android/hdpi.png" />
<icon density="xhdpi" src="www/res/icon/android/xhdpi.png" />
<icon density="xxhdpi" src="www/res/icon/android/xxhdpi.png" />
I read http://devgirl.org/2013/09/12/phonegap-icons-and-splash-screens-help/
and the steps given here are already happening.
In my /platforms/android/res/ the desired icons and screens appear in the right drawable folder.
I dont know what i am doing wrong. cant just get the icon to show up.
I am not using the phonegap desktop app
Use the same filename (ic_launcher.png is the default and most common one) for all icons, while they are in different folders, and change your icons call in the config.xml file to this:
<icon src="folder-hdpi/ic_launcher.png"
gap:platform="android"
gap:density="hdpi"/>
<icon src="folder-mdpi/ic_launcher.png"
gap:platform="android"
gap:density="mdpi"/>
<icon src="folder-xhdpi/ic_launcher.png"
gap:platform="android"
gap:density="xhdpi"/>
<icon src="folder-xxhdpi/ic_launcher.png"
gap:platform="android"
gap:density="xxhdpi"/>
<icon src="folder-xxxhdpi/ic_launcher.png"
gap:platform="android"
gap:density="xxxhdpi"/>
I created custom icons and splash screens for my phonegap android application. I created the phonegap application by using 'phonegap create' and I replaced all the stock icons and splash screens with custom made icons and splash screens.
Below is my folder structure of the images and splash after executing 'phonegap create' command
-myproject
--www
---icon.png
---res
----icon
-----android
------icon-36-ldpi.png
------icon-48-mdpi.png
------icon-72-hdpi.png
------icon-96-xhdpi.png
----screen
-----android
------screen-hdpi-landscape.png
------screen-hdpi-portrait.png
------screen-ldpi-landscape.png
------screen-ldpi-portrait.png
------screen-mdpi-landscape.png
------screen-mdpi-portrait.png
------screen-xhdpi-landscape.png
------screen-xhdpi-portrait.png
Below is the config.xml
<icon src="www/icon.png" />
<icon gap:platform="android" gap:qualifier="ldpi" src="www/res/icon/android/icon-36-ldpi.png" />
<icon gap:platform="android" gap:qualifier="mdpi" src="www/res/icon/android/icon-48-mdpi.png" />
<icon gap:platform="android" gap:qualifier="hdpi" src="www/res/icon/android/icon-72-hdpi.png" />
<icon gap:platform="android" gap:qualifier="xhdpi" src="www/res/icon/android/icon-96-xhdpi.png" />
Now I execute the 'phonegap build android' I dont see all the icons and splash screens are not copied to platforms\android\res folder. I only see the stock phonegap icons and splash screens.
I dont want to manually copy the icons and splash screens for each platform. It should happen automatically while building the phonegap for a target platoform. How should I do that.
Problem solved after moving the config.xml inside www folder and removed all www/ references in config.xml.
I.e,. the image paths should be relative where the config.xml exists.
Other way (works for me) using gap:density="ldpi" without moving any file
<icon gap:platform="android" gap:qualifier="ldpi" gap:density="ldpi" src="www/res/icon/android/icon-36-ldpi.png" />
<icon gap:platform="android" gap:qualifier="mdpi" gap:density="mdpi" src="www/res/icon/android/icon-48-mdpi.png" />
<icon gap:platform="android" gap:qualifier="hdpi" gap:density="hdpi" src="www/res/icon/android/icon-72-hdpi.png" />
<icon gap:platform="android" gap:qualifier="xhdpi" gap:density="xhdpi" src="www/res/icon/android/icon-96-xhdpi.png" />
I'm building a Phonegap application which I want to publish on as many platforms as possible.
I've found some documentation on icons and splash screens on the phonegap site.
https://build.phonegap.com/docs/config-xml
http://wiki.phonegap.com/w/page/36905973/Icons%20and%20Splash%20Screens
But can't find a complete list for someone who wants to publish for all devices on IOS(including iPad3), Android, BlackBerry, and Windows phone.
Can someone post a complete list of icon sizes and splash screen dimensions for all devices on all Phonegap supported OSs?
EDIT:
Also include any data that must be attached in the config.xml or specific names.
e.g. gap:platform="ios"
https://github.com/phonegap/phonegap/wiki/App-Icon-Sizes
I found this link with some sizes
Hi Please find the size on Iphone6 or more
<icon src="res/icons/ios/Icon-83.5#2x.png" width="167" height="167" />
iPad and iPad mini
<icon src="res/icons/ios/Icon-76#2x.png" width="152" height="152" />
iPhone 6s, iPhone 6, iPhone 5, iPhone 4s
<icon src="res/icons/ios/Icon-60#2x.png" width="120" height="120" />
iOS 6
<icon src="res/icons/ios/icon#2x.png" width="114" height="114" />
iPad 2 and iPad mini
<icon src="res/icons/ios/Icon-76.png" width="76" height="76" />
Spotlight search
<icon src="res/icons/ios/Icon-60.png" width="60" height="60" />
iOS6
<icon src="res/icons/ios/icon.png" width="57" height="57" />
I'm building a Sencha Touch + PhoneGap app for android and iOS (iPhone & iPad). I'm having major issues with PhoneGap choosing the correct icons and splash screens to display for the correct devices.
For example:
Android loads the correct main icon, however, it will load a splash screen that is very pixelated (I believe its loading one for the 320x460 iphone screen.)
iOS on both iPhone and iPad are showing the android icon and not loading the correct splash screens.
I'm really stuck on this and would appreciate any input on the matter, thanks in advance!
My code for config.xml is below:
<icon src="res/icons/icon.png" />
<icon src="res/icons/icon-blackberry-92.png" default="true" />
<icon src="res/icons/icon-blackberry-92-hover.png" hover="true" />
<icon src="res/icons/icon.png" width="57" height="57"/>
<icon src="res/icons/icon-72.png" width="72" height="72"/>
<icon src="res/icons/icon#2x.png" width="114" height="114"/>
<icon src="res/icons/icon-android-36.png" width="36" height="36"/>
<icon src="res/icons/icon-android-48.png" width="48" height="48"/>
<icon src="res/icons/icon-android-72.png" width="72" height="72"/>
<gap:splash src="res/splash/Default#2x.png" width="640" height="960" />
<gap:splash src="res/splash/Default.png" width="320" height="460" />
<gap:splash src="res/splash/splash-screen-ios-ipad.png" width="786" height="1024" />
<gap:splash src="res/splash/splash-screen-400x800.png" width="400" height="800" />
<gap:splash src="res/splash/Default.png" />
You need to specify the launch image file (UILaunchImageFile) property in your application's info.plist:
For example, if you set the value for the key UILaunchImageFile~ipad to iPad, your file names should be iPad-Portrait.png and iPad-Landscape.png. You could similarly change it for the iPhone, or use the default (Default.png) for iPhone.
This is defined in Information Property List Files.
In the newest Phonegap Xcode build, you can drag and drop the images you want to use as splashscreens or icons into the GUI area in XCode under Targets/Summary. That should allow you to add those in directly. What version of Xcode are you using ?? I can add in more specific details if I know what version it is.