Html(超文本标记语言)编写格式与常用控件归纳
2014-02-25 18:54
435 查看
HTML(Hyper Text Markup Language)--超文本标记语言
1.格式:
<html>
<head>
标题内容
</head>
<body>
实体内容
</body>
</html>
2.表格:
<table>
<tr>
// 行(tABLErOW),<th(tablehead)>加粗居中
<td>aa</td>
// 列
<td>aa</td>
// 第二列
</tr>
<tr>
// 第二行
</tr>
</table>
3.表单(Form):
<form>
username:<input type = "text">
// 输入框
password:<input type = "password">
// 密码框
兴趣:吃饭<input type = "checkbox">
// 复选框
睡觉<input type = "checkbox">
打豆豆<input type = "checkbox">
// 但选项
性别:男<input type = "radio" name = "gender">
女<input type = "radio" name = "gender">
// 下拉框
学历:<select>
<option>小学</option>
<option>初中</option>
<option>高中</option>
<option>大学</option>
</select>
评论:<textarea>
// 内容区域
</textarea>
文件上传:<input type = "file"> // 选择文件
<input type = "submit" value = "submit">
// 提交
<input type = "reset" value = "reset">
// 刷新
<input type = "button" value = "button">
// button
<input type = "button" value = "button" onclick = "javascript:alert('hello world');">
// 带动作的按钮
图片:<img src = "小猴.jpg">
//图片地址可为连接url
</form>
注:每个控件中均有类似的属性,譬如<input type="text" name="username" id="usernameid">
input这个控件里面有三个属性,分别是type、name与username。可设置更多的属性,每个属性之间以空格隔开
4.注释
<!-- 注释内容 -->
5.符号
<br>
// 换一行
 
// 空格
6.浏览器内核:
WebKit, trident
1.格式:
<html>
<head>
标题内容
</head>
<body>
实体内容
</body>
</html>
2.表格:
<table>
<tr>
// 行(tABLErOW),<th(tablehead)>加粗居中
<td>aa</td>
// 列
<td>aa</td>
// 第二列
</tr>
<tr>
// 第二行
</tr>
</table>
3.表单(Form):
<form>
username:<input type = "text">
// 输入框
password:<input type = "password">
// 密码框
兴趣:吃饭<input type = "checkbox">
// 复选框
睡觉<input type = "checkbox">
打豆豆<input type = "checkbox">
// 但选项
性别:男<input type = "radio" name = "gender">
女<input type = "radio" name = "gender">
// 下拉框
学历:<select>
<option>小学</option>
<option>初中</option>
<option>高中</option>
<option>大学</option>
</select>
评论:<textarea>
// 内容区域
</textarea>
文件上传:<input type = "file"> // 选择文件
<input type = "submit" value = "submit">
// 提交
<input type = "reset" value = "reset">
// 刷新
<input type = "button" value = "button">
// button
<input type = "button" value = "button" onclick = "javascript:alert('hello world');">
// 带动作的按钮
图片:<img src = "小猴.jpg">
//图片地址可为连接url
</form>
注:每个控件中均有类似的属性,譬如<input type="text" name="username" id="usernameid">
input这个控件里面有三个属性,分别是type、name与username。可设置更多的属性,每个属性之间以空格隔开
4.注释
<!-- 注释内容 -->
5.符号
<br>
// 换一行
 
// 空格
6.浏览器内核:
WebKit, trident
相关文章推荐
- 通过Mootools 1.2来操纵HTML DOM元素
- rm格式插入广告代码
- WEB标准网页布局中尽量不要使用的HTML标签
- flex 控件的重要属性
- Flash 与 html 的一些实用技巧
- html工作中表格<tbody>标签的使用技巧
- HTML 向 XHTML1.0 兼容性指导
- web下载的ActiveX控件自动更新
- 没有文件大小限制并免费的PDF到HTML转换工具
- css实现气泡框效果(实例加图解)
- html链接与文本标签们
- html活用软字符连接符
- 浅谈html中id和name的区别实例代码
- Android的TextView与Html相结合的具体方法
- 『jQuery』.html(),.text()和.val()的概述及使用
- php下过滤HTML代码的函数
- PHP HTML代码串截取代码
- .net后台获取html控件值的2种方法
- 网页的HTML静态化_网站优化之谈
- ASP.NET的HtmlForm控件学习及Post与Get的区别概述