user1324258
user1324258

Reputation: 561

Differences in rendering mobile chrome and android native browser

When testing my desktop (not responsive) website on my smartphone, i noticed differences in rendering the site in chrome (34.01847.114) and in the native Android browser (4.3). In Chrome the page is rendered without zoom as i want. In the native browser the paged is zoomed in. I do not use any viewprt-tag. When i set the viewport tag to

<meta name="viewport" content="width=device-width">

chrome behaves like the native browser and zoomes.

So i do not want any zoom, i want the site to be rendered in full resolution.

Upvotes: 6

Views: 1154

Answers (2)

hexalys
hexalys

Reputation: 5257

Are you sure that the page is in fact zoomed in the Android browser? My observations are that a previous zoom is often kept active if you just reload the same page over and over, which can be misleading you into thinking that this is how the page will load for users. However, use of refresh/reload aside, the page will load fine when normally loaded. Because of that, I'd advise to make sure you navigate to a new page when it comes to check on zoom behavior reliably.

Otherwise, if you still have issues and your desktop site has a fixed-width, you can simply set the viewport to that:

<meta name="viewport" content="width=fixed-width,initial-scale=1">

Where fixed-width is your fixed desktop target width in pixels.

That will give you a full width and rescale accordingly to each mobile device's screen size.

Upvotes: 0

Hige
Hige

Reputation: 144

To prevent zoom you shoyld use:

<meta name="viewport" content="initial-scale=1">

Hope it helps :)

Upvotes: 1

Related Questions