Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disabling zoom meta tag

What's the comlete version of the zoom disabling viewport meta tag?

I have tried with: <meta name="viewport" content="width=device-width, initial-scale=1">

but it just sets the appropriate scale and doesn't prevent zooming.

I also tried with: <meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0,target-densitydpi=device-dpi, user-scalable=no" />

But it just doesn't work, I can still pinch zoom on my mobile.

like image 857
Tommy D Avatar asked Dec 01 '22 00:12

Tommy D


2 Answers

It finally worked using that this way:

<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
like image 91
Tommy D Avatar answered Dec 09 '22 13:12

Tommy D


You can use this:

<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0,target-densitydpi=device-dpi, user-scalable=no" />
like image 31
Amar Syla Avatar answered Dec 09 '22 14:12

Amar Syla