html - Bootstrap 表格边框在 Firefox 中无法正确显示

标签 html css twitter-bootstrap

Bootstrap 表格边框在 Firefox 中无法正确显示。我在元素中创建了一个表,但它在 Firefox 中显示不正确。但 Chrome 没问题。

enter image description here

#product-attribute-specs-table th {border-bottom: medium none;border-radius: 0;border-right: medium none;box-shadow: none;color: #333333;display: block;font-size: 100%;font-weight: 600;line-height: 1.42857;text-align: left;    }
 <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
<table id="product-attribute-specs-table" class="data-table table table-striped">
  <tbody>
    <tr even="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr odd="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr even="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr odd="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr even="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr odd="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr even="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr odd="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr even="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr odd="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr even="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr odd="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr even="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr odd="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
    <tr even="">
      <th class="label ">Test 1</th>
      <td class="data">Test 2</td>
    </tr>
  </tbody>
</table>

最佳答案

display: block 更改为 display: table-cell

CSS:

#product-attribute-specs-table th {
  border-bottom: medium none;
  border-radius: 0;
  border-right: medium none;
  box-shadow: none;
  color: #333333;
  display: table-cell;
  font-size: 100%;
  font-weight: 600;
  line-height: 1.42857;
  text-align: left;
}

希望对你有帮助

享受 :)

关于html - Bootstrap 表格边框在 Firefox 中无法正确显示,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39387948/

相关文章:

javascript - 隐藏显示不适用于多个 div

javascript - 使用 js 变量或用户输入来更改 Bootstrap 日期选择器中的日期格式

tabs - 如何在悬停而不是单击时使用 twitter Bootstrap 选项卡?

jquery - 如何在 jquery mobile 中将标签放在输入元素顶部

python - 如何防止 LXML 错误 'failed to load external entity'

javascript - 我的 jQuery 'KeyCode' 代码不工作

javascript - 使用 JavaScript 编辑 CSS 渐变

html - 如何创建双色导航栏?

java - 如何在表vaadin中设置复选框的大小

css - 如何在 bootstrap 中将多行标签的行居中?