Any ideas why I am having issues with this?

+2 Stuart Abbott · August 5, 2014
<table>
    <thead>
      <tr>
        <!-- adding colspan can make a cell span multiple columns -->
        <th colspan="2" style="color: Blue;">Stock</th>
      </tr>
      <tr style="color: Navy; border-bottom: 1px solid black">
        <th>Item Number</th>
        <th>Cost (GBP)</th>
      </tr>
    </thead>
    <tbody style="color: Maroon">
      <tr>
        <td>One</td>
        <td>£9.99</td>
     </tr>
      <tr>
        <td>Two</td>
        <td>£17.99</td>
      </tr>
      <tr>
        <td>Three</td>
        <td>£29.99</td>
      </tr>
    </tbody>
  </table>

The larger text above is my issue. The color attribute works without a hitch, but there is no border at all! I hope someone can help

Post a Reply

Replies

Oldest  Newest  Rating
0 Stuart Abbott · August 5, 2014
Fixed it. Turns out, the major issue was that the main table tag needed to have:

border-collapse: collapse

All working well now :)
  • 1

HTML / CSS / Web Design

107,339 followers
About

Discuss, share, ask, learn and teach HTML5 and CSS3.

Links
Moderators