2019-04-01表格和表单

html
表格

table:

  1. table属性:
  • align="center" 居中
  • align="right" 居右
  • 默认在左(left)
    -cellspacing="" :单元格的边距
    -cellpadding="":边框与单元格的距离
    2.tr属性:
    -align="center" 居中
    -th与td用法一样,只是th能使文字加粗
<html>
    <head>
        <meta charset="utf-8"/>
        <title>个人简历</title>
    </head>
    <body>
       <table border="1" width="800px" height="150px" align="center" bgcolor="#000080">
            <tr align="center">
                <th rowspan=3>个人信息</th>
                <th>姓名</th>
                <td>张三</td>
                <th>性别</th>
                <td>男</td>
                <th>婚姻状况</th>
                <td>未婚</td>
                <th rowspan=3>照片</th>
            </tr>
            <tr align="center">
                <!-- <td>个人信息</td> -->
                <th>出生地</th>
                <td>河北</td>
                <th>户口</th>
                <td>泊头</td>
                <th>年月日</th>
                <td>1999/11/11</td>
                <!--<td >照片</td>-->
            </tr>
            <tr align="center">
                <!--<td>个人信息</td>-->
                <th>身份证</th>
                <td colspan=3>000000</td>
                <!-- <td>性别</td>
                <td>男</td> -->
                <th>手机</th>
                <td>151000000</td>
                <!--<td>照片</td>-->
            </tr>
       </table>
    </body>
</html>

表单

input:属性

  • type: text(文本) 默认

  • password(密码)
    -radio (单选框)
    -checkbox(复选框)

      <input type="text">
      密码:<input type="password">
    

单选框

<form>
    <input type="radio" name="sex" value='boy'> 男
    <input type="radio" name="sex" value="girl"> 女
</form>

复选框

你们的爱好:
           <input type="checkbox" name="eat" value='eat'> 吃 
           <input type="checkbox" name='play' value='play'> 玩
           <input type="checkbox" name="loveMe" value='loveMe'> 爱自己
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容

  • 有序列表(ordered list) 作用: 给一堆内容添加有序列表语义(一个有顺序整体), 列表中的条目有先后之...
    Jackson_yee_阅读 454评论 0 1
  • 概述 在网易云课堂学习李南江老师的《从零玩转HTML5前端+跨平台开发》时,所整理的笔记。笔记内容为根据个人需求所...
    墨荀阅读 2,367评论 0 7
  • 一,HTML语言的一般语法: 1,围堵标记:<>… 1)带属性的标记: … 2)无属性的标记:加粗 居中 标题 2...
    清水易蓝阅读 1,284评论 0 2
  • 浏览器与服务器的基本概念 浏览器(安装在电脑里面的一个软件) 作用: ①将网页内容渲染呈现给用户查看。 ②让用户通...
    云还灬阅读 1,154评论 0 0
  • html 表格 table:1. table属性:- align="center" 居中- align="righ...
    0db50ee67d73阅读 226评论 0 0