嗨,我有以下代码。当数据显示在屏幕上时,也会打印空白区域。如何在显示记录时调整/更改我的代码以消除空格。谢谢。
<?php
$con=mysql_connect('localhost','root') or die ("Server connection failure!");
$db=mysql_select_db('regional_data',$con) or die ("Couldn't connect the database");
$SQLa="SELECT * FROM newchk WHERE dist_chk='$distUsr'";
$runa=mysql_query($SQLa,$con) or die ("SQL Error");
$nora=mysql_num_rows($runa);
echo "<table cellpadding='2' class='tablet' cellspacing='0'>";
echo
"<tr>"
."<th>"."Starting Cheque No"."</th>"
."<th>"."Ending Cheque No"."</th>"
."<th>"."Total No of Cheques"."</th>"
."</tr>";
while ($reca = mysql_fetch_array($runa))
{
echo "<tr>";
echo "<td>".$reca["sbstart"]."</td>";
echo "<td>".$reca["sbend"]."</td>";
echo "<td>".$reca["totsb"]."</td>";
echo "</tr>";
}
echo "</table>";
?>