This is how my current table looks like:

I would prefer the table has no border but contains internal lines. That means there should only be 8 horizontal lines. How do I achieve this?
Here are my codes:
<table class="table">
<?php
$file = fopen("Book1.csv","r");
$data = array();
while($row = fgetcsv($file)) {
$data[] = $row; //Get all the data
}
if($data){
$n_columns = count($data[0]); //Get number of columns
}
echo '<table border="0">';
for ($col = 0; $col < $n_columns; $col++) {
echo '<tr>';
foreach ($data as $row_k => $row) {
if ($row_k == 0) {
echo '<th>';
} else {
echo '<td>';
}
echo $row[$col] ?? '';
if ($row_k == 0) {
echo '</th>';
} else {
echo '</td>';
}
}
echo '</tr>';
}
echo '</table>';
?>
</table>
<style type="text/css">
table{
border-color: #17a2b8;
}
</style>
>Solution :
Try this:
table {
border-collapse: collapse;
width: 100%;
}
tr {
border-bottom: 1px solid #17a2b8;
}