php webpage is not full on the mobile phone
When the webpage is displayed on the mobile phone, a meta## needs to be set #Metadata (Metadata is also called intermediary data and relay data, which is the data that describes the data). In this way, the size of the web page will adapt to our mobile screen. Add in the head tag of the html:
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0"/>
css style of ##body is body{
padding: 0;
margin: 0;
width: 100%;
}
1, < meta name="format-detection"/>
When browsing on a mobile phone, this tag is used to specify whether to display the mobile phone number in the web page content as a dialing hyperlink.
The default value on iPhone is:<meta name="format-detection" content="telephone=yes"/>
<meta name="format-detection" content="telephone=no"/>
<meta name=”apple-mobile-web-app-capable” content=”yes” />
3.
The function is to control the status bar display style:
<meta name=”apple-mobile-web-app-status-bar-style” content=”default” /> <meta name=”apple-mobile-web-app-status-bar-style” content=”black” /> <meta name=”apple-mobile-web-app-status-bar-style” content=”black-translucent” />
default:default; black: pure black; black-translucent: translucent gray
For more PHP related knowledge, please visit
The above is the detailed content of The php web page is not full on the left and right sides on the mobile phone. For more information, please follow other related articles on the PHP Chinese website!