【发布时间】:2018-01-14 15:55:19
【问题描述】:
>
</tr>
<?php
$conn = mysqli_connect("localhost", "root", "", "engine");
if ($conn-> connect_error) {
die("connection files:" . $conn-> connect_error);
}
$sql = "SELECT location , brand, model, origin, mfgdate from engines ";
$result = $conn-> query($sql);
if ($result-> num_rows > 0){
while ($row = $result-> fetch_assoc()){
echo "<tr><td>".
$row["location"] . "</td<td>" .
$row["brand"] . "</td><td>".
$row["model"] . "</td><td>".
$row["origin"] . "</td><td>".
$row["mfgdate"] . "</td></tr>";
}
echo "</table>";
}
else{
echo "0 result";
}
$conn->close();
?>
</table>
其实 "test"=location test1=brand test2=model test3= origin and date enter is =mfgdate
请帮我安排餐桌
【问题讨论】:
-
只需修复此行中缺少的
>:$row["location"] . "</td><td>" . -
您使用的是哪个 IDE?我很惊讶它没有显示 colo(u)r 的错误