ez-api/includes/load_love_wall.php

9 lines
319 B
PHP
Raw Normal View History

2024-10-29 13:13:37 +08:00
<?php
include 'db.php';
$stmt = $pdo->query("SELECT love_wall.content, users.username FROM love_wall JOIN users ON love_wall.user_id = users.id ORDER BY love_wall.created_at DESC");
while ($row = $stmt->fetch()) {
echo "<div class='love-message'><strong>{$row['username']}:</strong> {$row['content']}</div>";
}
?>