Reputation: 17681
Is it possible to force an app to display a site in normal resolution instead of large?
I am building an app which contains non-dynamic imagery - so I need to add additional stylesheets for each of the main screen sizes, the test phones I have been working with displayed the screen as a 320px wide until I upgraded the version of jquery library I had been using and it now displays as a 420px size.
I'm happy to make style sheets for both, but as it looked fine in the first place so I wonder whether it is possible to force the width to stay at 320? It would just save me a task and make the app lighter.
Any suggestions?
Cheers Paul
Upvotes: 1
Views: 157
Reputation: 1653
As you are building site for mobile browsers, there is a direct way to list the width for your site, and the phone's browser will resize it accordingly to device specs.
Try
<meta name="viewport"
content="width=device-width, initial-scale=1, maximum-scale=1">
Specific to your case
<meta name="viewport" content="width=320px">
Upvotes: 2
Reputation: 76003
It may not be as easy as putting max-width: 320px
somewhere but if you use your developer tools to inspect the DOM to find-out what styles are being applied you can limit the size of your website with max-width
.
Here is a demo: http://jsfiddle.net/LV9Kv/ (click the content to change it's size with only the max-width
property)
Upvotes: 1