-1

I noticed that my table, in which i set a border-collapse:collapse and border-bottom: 1px solid grey, has a thicker line between the rows every 5th row. How can I get them to also be 1px?

I also noticed that I cannot set a border-radius. Why is that?

Here's my code:

.list table {
    margin: 0 auto;
    width: 95%;
    border-collapse: collapse;
    border: 2px solid black;
    border-radius: 10px; //HAS NO EFFECT
}

.list th, .list td {
    border-bottom: 1px solid grey;
    padding: 10px;
}

1 Answers1

0

No problem with thicker border-bottom for me here. So your problem most likely lies within your HTML which you did not share...

.list table {
    margin: 0 auto;
    width: 95%;
    border-collapse: collapse;
    border: 2px solid black;
    border-radius: 10px; //HAS NO EFFECT
}

.list th, .list td {
    border-bottom: 1px solid grey;
    padding: 10px;
}
<div class="list">
  <table>
    <tr>
      <th>Header 1</th>
      <th>Header 2</th>
      <th>Header 3</th>
    </tr>
    <tr>
      <td>Row 1 Data 1</td>
      <td>Row 1 Data 2</td>
      <td>Row 1 Data 3</td>
    </tr>
    <tr>
      <td>Row 2 Data 1</td>
      <td>Row 2 Data 2</td>
      <td>Row 2 Data 3</td>
    </tr>
    <tr>
      <td>Row 3 Data 1</td>
      <td>Row 3 Data 2</td>
      <td>Row 3 Data 3</td>
    </tr>
    <tr>
      <td>Row 4 Data 1</td>
      <td>Row 4 Data 2</td>
      <td>Row 4 Data 3</td>
    </tr>
    <tr>
      <td>Row 5 Data 1</td>
      <td>Row 5 Data 2</td>
      <td>Row 5 Data 3</td>
    </tr>
    <tr>
      <td>Row 6 Data 1</td>
      <td>Row 6 Data 2</td>
      <td>Row 6 Data 3</td>
    </tr>
    <tr>
      <td>Row 7 Data 1</td>
      <td>Row 7 Data 2</td>
      <td>Row 7 Data 3</td>
    </tr>
    <tr>
      <td>Row 8 Data 1</td>
      <td>Row 8 Data 2</td>
      <td>Row 8 Data 3</td>
    </tr>
    <tr>
      <td>Row 9 Data 1</td>
      <td>Row 9 Data 2</td>
      <td>Row 9 Data 3</td>
    </tr>
    <tr>
      <td>Row 10 Data 1</td>
      <td>Row 10 Data 2</td>
      <td>Row 10 Data 3</td>
    </tr>
    <tr>
      <td>Row 11 Data 1</td>
      <td>Row 11 Data 2</td>
      <td>Row 11 Data 3</td>
    </tr>
  </table>
</div>
Peter Lehnhardt
  • 4,375
  • 1
  • 14
  • 33