meta 標籤經常使用設置
<!-- 根據瀏覽器的屏幕大小自適應的展示合適的效果 -->
<meta name="applicable-device" content="pc,mobile" />
<!-- 移動端 瀏覽器中頁面將以原始大小顯示,不容許縮放 -->
<meta name="viewport" content="width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
<!-- 優先使用 IE 最新版本和 Chrome -->
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
//它必須顯示在網頁中除 title 元素和其餘 meta 元素之外的全部其餘元素以前。若是不是的話,它不起做用
<!-- iphone會把一串數字識別爲電話號碼,點擊的時候會提示是否呼叫,屏蔽這功能則把telephone設置爲no -->
<meta content="telephone=no" name="format-detection" />
<!-- iphone的私有標籤,默認值爲default(白色),能夠定爲black(黑色)和black-translucent(灰色半透明) -->
<meta content="black" name="apple-mobile-web-app-status-bar-style">
<!-- iphone設備的是有標籤 容許全屏模式瀏覽,隱藏瀏覽器導航欄 -->
<meta content="yes" name="apple-mobile-web-app-capable" />
<!-- 全屏顯示 -->
<meta content="yes" name="apple-touch-fullscreen" />
<!-- UC強制全屏 -->
<meta name="full-screen" content="yes">
<!-- QQ強制全屏 -->
<meta name="x5-fullscreen" content="true">
<!-- 屏蔽百度轉碼 -->
<meta http-equiv="Cache-Control" content="no-transform" />
<meta http-equiv="Cache-Control" content="no-siteapp" />
<!-- 定義網頁簡短描述 -->
<meta name="description" content="Cochemist">
<!-- 定義網頁關鍵詞 -->
<meta name="keywords" content="生物化學">
<!-- 定義網頁的做者 -->
<meta name="author" content="sun_Annie">
<!-- 避免HTML頁面緩存 -->
<meta http-equiv="pragma" content="no-cache" />
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<!-- 定義網頁的緩存過時時間 -->
<meta http-equiv="expires" content="Sunday 26 October 2016 00:00 GMT">
//因爲這是一個過去的日期,因此這個網頁只要一打開,就會直接到網站服務器從新下載頁面內容,而不是從cache調用。這是一種防止網頁被cache緩存的措施。
複製代碼