小白自用 也為了方便自己復(fù)制粘貼 勿噴
通用設(shè)置項(xiàng)
<!-- 頁面編碼 -->
<meta charset="UTF-8" />
<!-- 緩存與過期時(shí)間設(shè)置 -->
<meta http-equiv="Pragma" content="no-cache">
<meta http-equiv="Cache-Control" content="no-cache">
<meta http-equiv="x-dns-prefetch-control" content="on">
<meta http-equiv="Expires" content="0">
<!-- dns預(yù)加載(SEO優(yōu)化) -->
<link rel="dns-prefetch" />
<link rel="dns-prefetch" />
<!-- 寬度默認(rèn)100%全屏寬度,禁止手指縮放,初始縮放值1.0 -->
<meta name="viewport" content="width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
可配置項(xiàng)
<!-- ====根據(jù)使用配置Start==== -->
<meta content="yes" name="apple-mobile-web-app-capable">
<meta content="black" name="apple-mobile-web-app-status-bar-style">
<!-- 不自動(dòng)識(shí)別手機(jī)號(hào),郵箱地址 -->
<meta name="format-detection" content="telephone=no,email=no">
<!-- 頁面關(guān)鍵字優(yōu)化 -->
<meta name="keywords" content="H5頁面通用配置">
<!-- 頁面標(biāo)簽icon配置 -->
<link rel="icon" type="image/x-icon">
<!-- 一些國(guó)內(nèi)webkit內(nèi)核瀏覽器默認(rèn)使用極速模式 -->
<meta name="renderer" content="webkit">
<!-- 避免IE使用兼容模式 -->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!-- 針對(duì)手持設(shè)備優(yōu)化,主要是針對(duì)一些老的不識(shí)別viewport的瀏覽器,比如黑莓 -->
<meta name="HandheldFriendly" content="true">
<!-- 微軟的老式瀏覽器 -->
<meta name="MobileOptimized" content="320">
<!-- uc強(qiáng)制豎屏 -->
<meta name="screen-orientation" content="portrait">
<!-- QQ強(qiáng)制豎屏 -->
<meta name="x5-orientation" content="portrait">
<!-- UC強(qiáng)制全屏 -->
<meta name="full-screen" content="yes">
<!-- QQ強(qiáng)制全屏 -->
<meta name="x5-fullscreen" content="true">
<!-- UC應(yīng)用模式 -->
<meta name="browsermode" content="application">
<!-- QQ應(yīng)用模式 -->
<meta name="x5-page-mode" content="app">
<!-- windows phone 點(diǎn)擊無高光 -->
<meta name="msapplication-tap-highlight" content="no">
<!-- apple-touch-icon:在webapp下,指定放置主屏幕上 icon 文件路徑 -->
<link rel="apple-touch-icon" href="touch-icon-iphone.png">
<link rel="apple-touch-icon" sizes="76x76" href="touch-icon-ipad.png">
<link rel="apple-touch-icon" sizes="120x120" href="touch-icon-iphone-retina.png">
<link rel="apple-touch-icon" sizes="152x152" href="touch-icon-ipad-retina.png">
<!-- apple-touch-startup-image:在 webapp 下,設(shè)置啟動(dòng)時(shí)候的界面 -->
<link rel="apple-touch-startup-image" href="/startup.png" />