简体   繁体   中英

Increasing the spacing between table rows

The code below works all fine and dandy. However, I would like to put a space of maybe 16 pixels / one row height between each row pair shown below. How can I do this? I think this might be a CSS issue.

while ($row = mysql_fetch_array($result)) { 
    echo '<tr>';
    echo '<td class="sitename1"><a href="http://www.'.$row["url"].'">'.$row["title"].'</a></td>';
    echo '</tr>';
    echo '<tr>';
    echo '<td class="sitename2"><a href="http://www.'.$row["url"].'">'.$row["loginid"].'</a></td>';
    echo '</tr>';
    }
echo "</table>";

Thanks in advance,

John

您可以在有问题的td添加填充:

.sitename1 {padding-bottom:16px}

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM