ブログのリストから最初の3つの投稿をスキップする方法を知っているこんにちは、私は最初に3つが上に掲載されるのを望むから...?ブログリストから最初の3つの投稿をスキップするにはどうすればよいですか?
<?php
$query = "SELECT * FROM posts ";
$select_all_posts_query = mysqli_query($connection,$query);
while($row = mysqli_fetch_assoc($select_all_posts_query)){
$post_id = $row['post_id'];
$post_title = $row['post_title'];
$post_author = $row['post_author'];
$post_date = $row['post_date'];
$post_image = $row['post_image'];
$post_content = substr($row['post_content'],0,255);
$post_status = $row['post_status'];
if($post_status !== 'published') {
echo "<h1 class='text-center'> NO POST SORRY</h1>";
} else {
}
}
?>
最後の '}'がありません。それは単なるコピー/ペーストミスですか? –
コピー貼りミス – Electrobox