【发布时间】:2017-09-06 07:12:20
【问题描述】:
这是我的代码。有一个“编辑”链接。我想更新数据并使用该链接保存
$op_sql = "SELECT * FROM tbl_users";
$result = $con->query($op_sql);
if ($result->rowCount() > 0)
{
echo "<table class='table' style='margin-left: 301px; margin-top: 10px; background-color: white;'>-;
echo "<tr>";
echo "<th>ID</th>";
echo "<th>Name</th>";
echo "<th>Email</th>";
echo "<th>Date of Birth<th>";
echo "<th></th>"; echo "</tr>";
while($row = $result->fetch())
{
echo "<tr>";
echo "<td>" . $rowrID1 . "</td>";
echo "<td>" . $row['Name'] . "</td>";
echo "<td>" . $row['Email']. "</td>";
echo "<td>" . $row['Date of Birth'] . "</td>";
echo "<td><a href='?id=".$row['ID']."'>Edit</a></td>";
echo "</tr>";
}
echo "</table>"; unset($result);
【问题讨论】:
-
有什么问题??
-
在此处分享您的代码,而不是图片。这将很容易处理和分析。
-
在此处发布您的代码 insted of image
-
如果你能分享这个问题会更好。我们只知道这是你的代码......