Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Webpage starts zoomed in on mobile devices

Tags:

html

viewport

I'm using this code on my webpage

<meta name="viewport" content="width=1000, initial-scale=1.0, maximum-scale=1.0"> 

I would think the initial scale would make sure the webpage was zoomed out, but it doesn't. Any ideas?

I've tried this:

<meta name="viewport" content="width=device-width, initial-scale=1.0"/> 

But, I need the width to be set to 1000px or it doesn't look correct.

Answer:

<meta name="viewport" content="width=1000; user-scalable=0;" /> 
like image 865
EGHDK Avatar asked Jan 11 '13 05:01

EGHDK


People also ask

How do I stop my web page from zooming in?

By default, Chrome sets the zoom level to 100%. To manually adjust the settings, use the Ctrl key and “+” or “-” combos to increase or decrease the page magnification. If you are using a mouse, you can hold down the keyboard Ctrl key and use the mouse wheel to zoom in or out.

How do you turn off zoom on input focus on mobile devices?

Solution 1Set the window and body to a size that fills the screen-space, without exceeding it. This is why so many people have success with forcing input text-size to 16px; once you do that, its clear that you're WAY zoomed out.

How do I fix mobile view in HTML?

The < meta name="viewport" .. > line in the < head > makes your responsive page look normal on mobile devices.


1 Answers

initial-scale=1.0 tells the browser to set the zoom level to normal (i.e. not zoomed in or out). You only need width=1000:

<meta name="viewport" content="width=1000"> 
like image 60
Jeffery To Avatar answered Oct 04 '22 15:10

Jeffery To