Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I prevent resize on iPad

Tags:

ios

safari

ipad

I have a web app running on Safari on an iPad. I am starting the app from the iPad home page. I want the app to start in full-screen mode, and to continue running in full-screen mode (i.e. not showing the Safari address bar).

I want to prevent the "pinch-to-zoom" and pan/zoom functions so the page always remains static. How do I do this?

like image 797
Ben Avatar asked Jun 03 '12 10:06

Ben


1 Answers

If you put the following meta tag into the html output and then start the app from the homepage then it will be fullscreen when it runs:

<meta name="apple-mobile-web-app-capable" content="yes">

The following is to prevent the user from zooming:

<meta name="viewport" content="width=device-width,user-scalable=no">
like image 94
zaf Avatar answered Sep 30 '22 08:09

zaf