I have a table that is echo'd into the page and I need each different entry seperated by so much. here's the table.
echo '<table>';
while ($row = mysqli_fetch_array($data)) {
if(!empty($row['first_name'])) {
echo '<td class="viewpost">First Name:' . $row['first_name'] . '</td></tr>';
}
if(!empty($row['last_name'])) {
echo '<td class="viewpost">Last Name:' . $row['last_name'] . '</td></tr>';
}
if(!empty($row['post'])) {
echo '<td class="viewpost1">' . $row['post'] . '</td></tr>';
}
}
echo '</table>';
And the CSS
.viewpost {
border: 1.5px solid #367588;
background-color: #333;
margin-bottom:25px;
}
.viewpost1 {
border: 1.5px solid #367588;
background-color: #333;
margin-bottom:100px;
margin-left:10px;
}
And the two tables are not seperated on the page. Help