我需要桌子上的一些区域滚动条吗? [英] I need some area scroll-bar in table?
问题描述
请找到图片,然后您可以查看Jan和Dec列,我需要在两列空间区域具有Jan到Dec个月的意义上为该两列放置一个滚动条.
Please find the image and you can view the Jan and Dec column, I need to place a scroll bar for that two column in the sense two column space area has Jan to Dec months.
这可能用于桌子吗?
请帮助我!
以上问题获得了很好的答案.
Above Question got very good answer.
另一个帮助!
http://jsfiddle.net/anglimass/Ty29z/
请找到图像,然后您可以查看(供应商1引用)和(供应商6引用)列,我需要为两列放置一个滚动条,以使两列空间区域具有(供应商1引用)为(供应商6报价)供应商详细信息
please find the image and you can view the (vendor 1 quote) and (vendor 6 quote) column, I need to place a scroll bar for that two column in the sense two column space area has (vendor 1 quote)to (vendor 6 quote) vendor details
推荐答案
尝试一下:
HTML
<table style="text-align: left; width: 100%;" border="1" cellpadding="2" cellspacing="2">
<tbody>
<tr>
<th>Header 1</th>
<th>Header 2</th>
<th colspan="1" rowspan="5" style="border: medium none ; width: 100px; vertical-align: top;">
<div class="inner-table">
<table style="text-align: left; width: 500px; border:none" border="1" cellpadding="2" cellspacing="2">
<tbody>
<tr>
<th>Header 1</th>
<th>Header 2</th>
<th>Header 3</th>
<th>Header 4</th>
</tr>
<tr>
<td>a</td>
<td>a</td>
<td>a</td>
<td>a</td>
</tr>
<tr>
<td>b</td>
<td>b</td>
<td>b</td>
<td>b</td>
</tr>
<tr>
<td>c</td>
<td>c</td>
<td>c</td>
<td>c</td>
</tr>
</tbody>
</table>
</div>
</th>
<th>Header 4</th>
</tr>
<tr>
<td>a</td>
<td>a</td>
<td>a</td>
</tr>
<tr>
<td>b</td>
<td>b</td>
<td>b</td>
</tr>
<tr>
<td>c</td>
<td>c</td>
<td>c</td>
</tr>
<tr>
<td> </td>
<td> </td>
<td> </td>
</tr>
</tbody>
</table>
CSS
.inner-table {
width:100px;
overflow-x:scroll;
}
th {
height:20px;
}
演示
http://jsfiddle.net/andresilich/caq8F/4/
您可以摆弄CSS以轻松获得相同的样式.
You can fiddle with the CSS to get the same style easily.
:: EDIT ::清理了代码并更新了小提琴,为滚动条留出一些空间.
::: Cleaned up code and updated fiddle to include some space for the scroll bar.
这篇关于我需要桌子上的一些区域滚动条吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!