Mobile-side layout (viewport) method

Source: Internet
Author: User

Viewport Default has 6 properties

  • Width: Sets viewport (that is, the width of the browser as mentioned previously), which can be an integer or a string "Width-device"
  • Initial-scale: The initial zoom value of the page, as a number, can be a decimal
  • Minimum-scale: Allows the user's minimum zoom value to be a number, which can be a decimal
  • Maximum-scale: Allows the user's maximum zoom value, as a number, can be a decimal
  • Height: Sets the altitude of the viewport (which we do not normally use)
  • User-scalable: Whether the user is allowed to scale, ' no ' is not allowed, ' yes ' is allowed

We're putting this tag inside the head, like this.

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

So that we can control the viewport.

Mobile-side layout (viewport) method

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.