html表格(二)升级版
1、示例代码如下(转载):
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>表格</title>
<style type="text/css">
#table01{border: 1;width: 50%;align-content: center;}
</style>
</head>
<body>
<a id="top"></a>
<form action="#"method="post">
<table id="table01" border="0" width="50%"cellspacing="0"cellpadding="5%"align="center">
<tr>
<th align="left"><b></b></td>
<th align="left"><b>注册信息</b></td>
</tr>
<tr>
<td align="right"><label for="name">姓名:</label></td>
<td><input type="text"name="name"id="name"placeholder="请输入姓名"></td>
</tr>
<tr>
<td align="right">性别:</td>
<td><input type="radio"name="gender"id="male">男
<input type="radio"name="gender"id="female">女
</td>
</tr>
<tr>
<td align="right"><label for="age">年龄:</label></td>
<td><input type="text"name="age"id="age"placeholder="年龄"></td>
</tr>
<tr>
<td align="right"><label for="tel">电话:</label></td>
<td><input type="tel"name="tel"id="tel"placeholder="请输入电话号码"></td>
</tr>
<tr>
<td align="right">证件类型:</td>
<td><input type="radio"name="IDtype"id="IDcard">身份证
<input type="radio"name="IDtype"id="passport">护照
</td>
</tr>
<tr>
<td align="right"><label for="id">证件号码:</label></td>
<td><input type="text"name="id"id="id"placeholder="请输入证件号码"></td>
</tr>
<tr>
<td align="right">国家:</td>
<td><select size="1">
<option>中国</option>
<option>日本</option>
<option>韩国</option>
<option>俄罗斯</option>
<option>朝鲜</option>
<option>蒙古</option>
<option>印度</option>
<option>巴基斯坦</option>
<option>孟加拉</option>
<option>新加坡</option>
<option>印尼</option>
<option>乌拉圭</option>
<option>塞尔维亚</option>
</select>
</td>
</tr>
<tr>
<td colspan="2" align="center"><input type="submit"value="提交" style="color:#48DD22;"></td>
</tr>
</table>
</form>
<right>
<a href="#top"><input type="button" value="返回顶部" ></a></right>
</body>
</html>