您好,我希望能夠顯示 2022 年 1 月 25 日之後的用戶的註冊日期 但我的查詢總是顯示相同的日期
$sqlQuery = 'SELECT * FROM _users WHERE user_registered > "2022-01-25"'; $recipesStatement = $bdd->prepare($sqlQuery); $recipesStatement->execute(); $recipes = $recipesStatement->fetchAll(); // On affiche chaque date une à une foreach ($recipes as $recipe) { ?> <p><?php echo $recipe['user_registered']; ?></p> <?php }
P粉9589860702023-09-13 09:08:11
sqlQuery = 'SELECT * FROM _users WHERE user_registered > "2022-01-25 00:00:00"'; $recipesStatement = $bdd->prepare($sqlQuery); $recipesStatement->execute(); $recipes = $recipesStatement->fetchAll(); // On affiche chaque date une à une foreach ($recipes as $recipe) { ?> <p><?php echo $recipe['user_registered']; ?></p> <?php }