水平滚动的HTML表格(第一列固定) [英] HTML table with horizontal scrolling (first column fixed)

查看:117
本文介绍了水平滚动的HTML表格(第一列固定)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在想办法制作一张固定的第一列表(而其余的表格有一个水平溢出),我看到一个帖子中有一个类似的问题。但固定列位似乎没有解决。帮助?

I have been trying to think of a way to make a table with a fixed first column (and the rest of the table with a horizontal overflow) I saw a post which had a similar question. but the fixed column bit did not seem to be resolved. Help?

推荐答案

我有类似的表格样式:

I have a similar table styled like so:

<table style="width:100%; table-layout:fixed">
    <tr>
        <td style="width: 150px">Hello, World!</td>
        <td>
            <div>
                <pre style="margin:0; overflow:scroll">My preformatted content</pre>
            </div>
        </td>
    </tr>
</table>

这篇关于水平滚动的HTML表格(第一列固定)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆