Gitlab@Informatics

Skip to content
Snippets Groups Projects
Commit d81188e5 authored by 65160377's avatar 65160377
Browse files

Initial commit

parent 929491e2
Branches main
No related tags found
No related merge requests found
......@@ -106,3 +106,21 @@ if (!isset($_SESSION['login'])) {
echo "Welcome, " . $_SESSION['login']; // แสดงชื่อผู้ใช้ที่ล็อกอิน
?>
<a href="logout.php">Log Off</a>
<?php
$sql = "SELECT * FROM Tours";
$result = $conn->query($sql);
if ($result->num_rows > 0) {
while ($row = $result->fetch_assoc()) {
echo "ชื่อทัวร์: " . $row["TourName"] . "<br>";
echo "ปลายทาง: " . $row["Destination"] . "<br>";
echo "ราคา: " . number_format($row["Price"], 2) . " บาท<br>";
echo "วันที่เดินทาง: " . $row["StartDate"] . " ถึง " . $row["EndDate"] . "<br>";
echo "<hr>";
}
} else {
echo "ไม่มีทัวร์ในระบบ";
}
$conn->close();
?>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment