1个回答
展开全部
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Document</title>
</head>
<style type="text/css">
.table01,.table02{
border: 1px solid #ddd;
width: 400px;
height: 150px;
border-collapse: collapse;
}
.table02{
margin-top: 20px;
}
.table01 th,.table01 td,.table02 th,.table02 td{
border: 1px solid #ddd;
text-align: center;
}
</style>
<script type="text/javascript" src="http://apps.bdimg.com/libs/jquery/1.6.4/jquery.min.js"></script>
<script type="text/javascript">
$(function(){
$("#btn").click(function(){
$("#content").html("点表一的按钮我就添加内容");
});
});
</script>
<body>
<table>
<tr>
<th>表一</th>
<th>表一</th>
<th>表一</th>
</tr>
<tr>
<td>
<button id="btn">点我</button>
</td>
<td>一</td>
<td>一</td>
</tr>
</table>
<table>
<tr>
<th>表二</th>
<th>表二</th>
<th>表二</th>
</tr>
<tr>
<td>
<p id="content"></p>
</td>
<td></td>
<td></td>
</tr>
</table>
</body>
</html>
<html>
<head>
<meta charset="UTF-8">
<title>Document</title>
</head>
<style type="text/css">
.table01,.table02{
border: 1px solid #ddd;
width: 400px;
height: 150px;
border-collapse: collapse;
}
.table02{
margin-top: 20px;
}
.table01 th,.table01 td,.table02 th,.table02 td{
border: 1px solid #ddd;
text-align: center;
}
</style>
<script type="text/javascript" src="http://apps.bdimg.com/libs/jquery/1.6.4/jquery.min.js"></script>
<script type="text/javascript">
$(function(){
$("#btn").click(function(){
$("#content").html("点表一的按钮我就添加内容");
});
});
</script>
<body>
<table>
<tr>
<th>表一</th>
<th>表一</th>
<th>表一</th>
</tr>
<tr>
<td>
<button id="btn">点我</button>
</td>
<td>一</td>
<td>一</td>
</tr>
</table>
<table>
<tr>
<th>表二</th>
<th>表二</th>
<th>表二</th>
</tr>
<tr>
<td>
<p id="content"></p>
</td>
<td></td>
<td></td>
</tr>
</table>
</body>
</html>
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询