【发布时间】:2019-12-23 23:10:13
【问题描述】:
我想在表格中使用 Bootstrap Nav Pills,并在最后一个表格的行中使用“选项卡按钮”。 选项卡内容在表格之外。我试过了,但它不起作用。
https://jsfiddle.net/wxkd6r2q/
<table class="table">
<caption>List of users</caption>
<thead>
<tr>
<th scope="col">#</th>
<th scope="col">First</th>
<th scope="col">Last</th>
<th scope="col">Handle</th>
</tr>
</thead>
<tbody>
<tr>
<th></th>
<td> <a data-toggle="tab" href="#home">BUTTON HERE</a> </td>
<td> <a data-toggle="tab" href="#profile">BUTTON HERE</a> </td>
<td> <a data-toggle="tab" href="#contact">BUTTON HERE</a> </td>
</tr>
</tbody>
</table>
<div class="tab-content" id="myTabContent">
<div class="tab-pane fade show active" id="home" role="tabpanel">...home..</div>
<div class="tab-pane fade" id="profile" role="tabpanel">...profile...</div>
<div class="tab-pane fade" id="contact" role="tabpanel">...contact...</div>
</div>
【问题讨论】:
标签: javascript css twitter-bootstrap bootstrap-4