1.基本结构:
<!DOCTYPE html PUBLIC “-//W3C//DTD HTML 4.01 Transitional//EN” “http://www.w3.org/TR/html4/loose.dtd”>
<html>
<head>
<meta http-equiv=”Content-Type” content=”text/html; charset=UTF-8″>
<title></title>
</head>
<body>
</body>
</html>
2.文档类型:
(1)HTML 4.01
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
(2)HTML5
<!DOCTYPE html>
(3)XHTML 1.0
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd”>
3.头部:
(1)字符集
<meta http-equiv=”Content-Type” content=”text/html; charset=UTF-8″>
(2)引入JS
<script language=”javascript”></script>
<script language=”javascript” src=””></script>
<script language=”javascript”>var u=”__URL__”;var a=”__APP__”;</script>
<script language=”javascript” src=”__PUBLIC__/js/jquery-1.8.1.min.js”></script>
(3)引入CSS
<style type=”text/css”></style>
<link rel=”stylesheet” href=”” type=”text/css”>
(4)设置默认跳转
<base href=”” />
<base target=”_blank” />
(5)设置搜索引擎相关信息
<meta name=”description” content=”,,” />
<meta name=”keywords” content=”,,” />
4.主体:
(1)基本内容
<body onload=””>
<div id=”” class=””></div>
<div style=”clear:both;”>
(2)表单
GET方式提交:<form id="" action="" method="post"></form>
POST方式提交:<form id="" action="" method="get"></form>
携带文件提交:<form id="" action="" method="post" enctype="multipart/form-data"></form>
首页常用:
<input id=”username” name=”username” class=”” type=”text” placeholder=”用户名”></input>
<input id=”password” name=”password” class=”” type=”password” placeholder=”密码”></input>
<input id=”login_button” class=”button” type=”button” value=”登录” onclick=””></input>









