10

I'm trying to set the full screen mode on my iPhone Web App, I have read the Apple's documentation on apple-mobile-web-app-capable meta tag, but it doesn't work, can you help me? Thanks

ThinkingStiff
  • 64,767
  • 30
  • 146
  • 239
Cattani Simone
  • 1,168
  • 4
  • 12
  • 30

2 Answers2

16
<meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">

Make sure you do what Bala Clark mentioned

Its worth mentioning that these tags only work when the app is saved the home screen and launched from there

dan
  • 2,857
  • 6
  • 34
  • 60
Michaël
  • 6,676
  • 3
  • 36
  • 55
  • 5
    thoses meta tags are only working for iOs safari and only if the user added the website to his home screen. – Guillaume Gendre Jun 18 '12 at 12:35
  • 2
    Its worth mentioning that these tags only work when the app is saved the home screen and launched from there. – Bala Clark Aug 18 '13 at 19:00
  • I couldn't get this to work in iOS 7, and yes, I am launching from the saved home screen icon. – Makoto Jan 01 '14 at 11:43
  • I had the same problem until I found the answer that Bala Clark mentioned. You have to add the site to your home screen by selecting the box with up arrow in safari and then add to home screen, this is for ios 8, I have not tested in other versions of ios – dan Sep 13 '15 at 13:29
6

You can also add a javascript function :

<body onload="setTimeout(function() { window.scrollTo(0, 1) }, 100);">
Michaël
  • 6,676
  • 3
  • 36
  • 55