The resolution width of my mobile phone is 480px. I made a small webpage with a table specification width of 480px, and set the margin of the webpage to 0px using the margin attribute in css. However, when I access it on my mobile phone, the webpage is fine. The image has shrunk, and there are blank spaces on the left, right and bottom. Only the top part is at the top of the browser. Only by double-clicking the page can it be displayed according to the current width of the mobile phone. Moreover, it is obvious that there is still a blank space at the bottom of the webpage. How can I correctly set it to normal full-screen display on the mobile phone?
I want to achieve the effect of the first picture, but I can only achieve the effect of the first picture. The effect of the two pictures
http://baike.baidu.com/view/8539585.htm?fr=aladdin
http://baike.baidu.com/view/8539585.htm?fr=aladdin
http://baike.baidu.com/view/8539585.htm?fr=aladdin
Are there any experts who can give me advice? ? ? Thank you. . . .
Can’t just use height width 100%?
Can’t just use height width 100%?
Tried it, but it doesn’t workI’ve also been working on a mobile website recently, and it will work if I distribute it by percentage, because the screen of a mobile phone is also 100%
Mobile phones are becoming popular. Why . The problem you mentioned can be caused by several reasons. I don't dare to draw conclusions without seeing the code. Guess one, your header declaration file uses the page declaration of PC. Guess 2: You did not set the scaling ratio. Guess 3: You may have turned on the manual zoom ratio and then accidentally zoomed out when browsing the web. When you open the second page, the page will be zoomed on your phone screen according to your previous zoom ratio. I dare not guess the rest.
Do you use
*{padding:0;margin:0}
position:absolute;top:0;right:0;bottom:0;left:0