html - 手机上 td 周围的边框

标签 html css mobile html-table

在移动设备上查看时,td class="pos-nochange" 周围有一个边框,即使边框设置为 0px。我不明白的一件事是,为什么当用户在他们的移动设备上放大(放大)时,边框会变大或变小(看起来很不固定)?

<table style="font-family: Open Sans; font-size:12px; border:0px">
    <tbody>
        <tr>
            <td style="background-color: #44445e;" colspan="5" width="300">
                <div id="mleaguetable"></div>
                <div class="live"><span style="font-size:15px">LIVE</span>
                </div>
            </td>
        </tr>
        <tr>
            <th style="background-color: #050528; text-align: center; vertical-align: middle;" colspan="2" height="30"><strong><span style="color: #828293;">Pos</span></strong>
            </th>
            <th style="background-color: #050528; text-align: left; vertical-align: middle;" width="155"><strong><span style="color: #828293; padding: 0 0 0 5px;">Club</span></strong>
            </th>
            <th style="background-color: #050528; text-align: center; vertical-align: middle;" width="50"><strong><span style="color: #828293;">Pld</span></strong>
            </th>
            <th style="background-color: #050528; text-align: center; vertical-align: middle;" width="50"><strong><span style="color: #828293;">Pts</span></strong>
            </th>
        </tr>
        <tr>
            <td style="background-color: #51516d; vertical-align: middle; text-align: right;" width="30" height="30"><span style="color: #ffffff;">1</span>
            </td>
            <td class="pos-nochange" style="background-color: #51516d;"></td>
            <td style="background-color: #51516d; border-right: 1px solid #44445E;"><span style="color: #ffffff; padding: 0 0 0 5px;"><a href="/en-gb/clubs/profile.overview.html/arsenal"><span style="color: #ffffff;">Utd For Utd</span>
                </a>
                </span>
            </td>
            <td style="background-color: #51516d; text-align: center; border-right: 1px solid #44445E;"><span style="color: #ffffff;">5</span>
            </td>
            <td style="background-color: #51516d; text-align: center;"><strong><span style="color: #ffffff;">13</span></strong>
            </td>
        </tr>...</tbody>
</table>

最佳答案

使用border-collapse样式规则:

table
{
   border-collapse:collapse;
}

Fiddle Demo

关于html - 手机上 td 周围的边框,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20703079/

相关文章:

php - 如何从 HTML 按钮单击调用类中的 PHP 函数

css - 用 LESS 覆盖 css 类变量

c++ - 数字小键盘到移动小键盘模拟器。

android - html5立即捕获照片(&lt;input/>)而不要求选择现有照片

html - Bootstrap 4 中带有长文本的 5 列 ROW

javascript - jQuery 可拖动和透明 PNG - 可拖动区域被透明背景遮挡

javascript - 正确的链接使用

javascript - 更改 html 中当前事件段落的 css

html - 使用视频作为背景

java - 安卓工作室。可点击的进度条