When writing the HTML5 mobile phone page, we will find that the proportion of the elements displayed on the page is incorrect. What we need to add at this time is:
<meta name = Viewport Content = Width = Device-Width, Initial-SCALE = 1>
Either
<meta name = ViewPort Content = Width = Device-Width, Initial-SCALE = 1.0, Minimum-SCALE = 0.5, Maximum-Scale = 2.0, User-SCALABLE = YES />
Then let's explain this sentence:
ViewPort: It means the display window;
width = Device-Width, Initial-SCALE = 1.0: It means the width of the display window is equal to the screen width of the device, the initial-scale = 1.0, that is, the initial zoom ratio is 1.0;
Minimum-Scale: It means the minimum ratio allowed to be allowed
Maximum: It means the maximum ratio that allows scaling
User-SCALABLE: It means whether the user allows the user to scate the page. The value can be yes or NO
Example problem: Phenomenon:When the user clicks on the Input input box on the mobile page to edit the text, the page will be automatically enlarged
solve:Insert in the head of the page <head> label
<meta name = Viewport Content = Width = Device-Width, Initial-SCALE = 1.0, Minimum-SCALE = 1.0, Maximum-SCALE = 1.0 />
Or the user is not allowed to zoom the page user-scalable = NO
SummarizeThe above is the problem of solving the HTML5 mobile phone page zoom that I introduced to you. I hope it will be helpful to everyone. If you have any questions, please leave me a message. Xiaobian will reply to everyone in time. Thank you very much for your support for the VEVB Wulin website!