<?php
$batchcourseid = $_POST['batchcourseid'];
$coursestatus = $_POST['coursestatus'];
$batchname = $_POST['batchname'];
$conn=mysql_connect("localhost","root","qwerty");
mysql_select_db("MIS");
$sql=("SELECT * from batch where CourseID = '$batchcourseid' AND BatchName LIKE '%$batchname%'");
$results = mysql_query($sql, $conn);
?>
<table width="1070" height="54" border="1">
<tr>
<td height="23">BatchID</td>
<td>CourseID</td>
<td>Batch Name</td>
<td>Number Of Students</td>
<td>Start Date</td>
<td>End Date</td>
</tr>
<?php while($row = mysql_fetch_array($results)) ?>
<?php { ?>
<tr>
<td height="23"><?php echo $row['BatchID'] ?> </td>
<td><?php echo $row['CourseID']; ?> </td>
<td><?php echo $row['BatchName']; ?> </td>
<td><?php echo $row['NumStud']; ?> </td>
<td><?php echo $row['StartDate']; ?> </td>
<td><?php echo $row['EndDate']; ?> </td>
</tr>
<?php } ?>
这段代码应该在表格中给出一行。但它只是出现的空行。我做错了什么?所有的列和文本也存在