- H5标准声明,使用 HTML5 doctype,不区分大小写
<!DOCTYPE html>
<head lang=”en”>
<meta charset=’utf-8′>
<meta http-equiv=”X-UA-Compatible” content=”IE=edge,chrome=1″/>
<meta name=”description” content=”不超过150个字符”/>
<meta name=”keywords” content=””/>
<meta name=”author” content=”name, email@gmail.com”/>
<meta name=”robots” content=”index,follow”/>
<meta name=”viewport” content=”initial-scale=1, maximum-scale=3, minimum-scale=1, user-scalable=no”>
<meta name=”apple-mobile-web-app-title” content=”标题”>
- 添加到主屏后的标题(iOS 6 新增)是否启用 WebApp 全屏模式,删除苹果默认的工具栏和菜单栏
<meta name=”apple-mobile-web-app-capable” content=”yes”/>
<meta name=”apple-mobile-web-app-status-bar-style” content=”black”/>
<meta name=”format-detection” content=”telphone=no, email=no”/>
<meta name=”renderer” content=”webkit”>
<meta http-equiv=”X-UA-Compatible” content=”IE=edge”>
<meta http-equiv=”Cache-Control” content=”no-siteapp” />
- 针对手持设备优化,主要是针对一些老的不识别viewport的浏览器,比如黑莓
<meta name=”HandheldFriendly” content=”true”>
<meta name=”MobileOptimized” content=”320″>
<meta name=”screen-orientation” content=”portrait”>
<meta name=”x5-orientation” content=”portrait”>
<meta name=”full-screen” content=”yes”>
<meta name=”x5-fullscreen” content=”true”>
<meta name=”browsermode” content=”application”>
<meta name=”x5-page-mode” content=”app”>
<meta name=”msapplication-tap-highlight” content=”no”>
<meta http-equiv=”pragma” content=”no-cache”>
<meta http-equiv=”cache-control” content=”no-cache”>
<meta http-equiv=”expires” content=”0″>