我正在尝试成功登录表单。这是我的activation.php文件。这里有点帮助pelase :)。
这是我的代码(很抱歉没有创建代码段,因为我无法找到要创建它的网站):
<?php
$servername = "localhost";
$dbname = "dbtechnerdzzz";
// Create connection
$conn = new mysqli($servername, $dbname);
//Check connection
if ($conn->connect_error) {
die("Connection failed: " . $conn->connect_error);
}
$sql = "SELECT * FROM accounts";
$result = $conn->query($sql);
if ($result->num_rows > 0) {
// output data of each row
while($row = $result->fetch_assoc()) {
echo "id: " . $row["UserID"]. " - Name: " . $row["Username"]. " " . $row["Password"]. $row["Email"]. " - Name: " . $row["CreatedOn"]. " " . $row["DateOfBirth"]. "<br>";
}
} else {
echo "0 results";
}
$conn->close();
?>