Reputation: 1557
I recently upgraded my iphone 6 from iOS 8 to iOS 9. After I opened an app that displayed fine when launched before, it now shows black borders at the top and bottom of the screen, and it automatically loads phonegap logo as the splash screen. Any suggestions on how I can get rid of these issues?
I saw a few articles online making several suggestions but none works for me, one mentioned modifying the config.xml preference from TRUE
to FALSE
and that did not help.
<preference name="auto-hide-splash-screen" value="FALSE" />
'
I also installed the phoneGap splashscreen plugin and that did not help. Any suggestion would be appreciated, I will be testings different things and will share it here if I find a solution.
Thanks in Advance.
Upvotes: 0
Views: 1275
Reputation: 8550
As for myself, the problem was simply that I was using a jpg image for the 640x1136 splash screen.
It worked in iOS7 and 8 but showed black bars at the top and at the bottom of the screen in iOS9.
Changed the format and extension of the file to PNG, changed the path in the config file to reflect the change of extension and it started working again.
If you are starting a project, do yourself a favor : Don't use phonegap, it seems attractive on paper but it is hacks on hacks.
Upvotes: 1
Reputation: 1557
Below is the solution, I reckon other developers will experience this issue sooner or later as well. Credit to @filmkit over by the phonegap community board.
screen-iphone-portrait-2x.png
screen-iphone-portrait-568h-2x.png
screen-iphone-portrait-568h-2x.png
<preference name="auto-hide-splash-screen" value="false"/>
2a. Also verify that the paths for each splash screen do not have the 'www' in front of it. They should be: res/screen/ios
I then copied my config.xml file from: myProject/ to: myProject/www
Then edit myProject/www/js/index.js and below this line:
app.receivedEvent('deviceready');
-
add this:
setTimeout(function() {
navigator.splashscreen.hide();
}, 2000);
Andre
Upvotes: 0