make 2 or more post in bootsrap
Clash Royale CLAN TAG#URR8PPP
make 2 or more post in bootsrap
I am making a CMS
and I want to add two or more content post in every row, I can made one post in one columns, please see my code below. I am using PHP
, HTML
and bootstrap
.
CMS
PHP
HTML
bootstrap
How can I add two or more content post in every row?
Code:
<div class="container">
<div class="row">
<!-- Post Content Column -->
<div class="col-lg-4 border border-dark rounded">
<?php
$query = "SELECT * FROM POSTS";
$run_query_post = mysqli_query($connection, $query);
while ($row = mysqli_fetch_assoc($run_query_post))
$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, 50);
$post_status = $row['post_status'];
if ($post_status !== 'published')
echo "No Post in Here";
else
?>
<!-- Title -->
<h1 class="mt-4"><a href="post.php?p_id=<?php echo $post_id; ?>"><?php echo $post_title; ?></a></h1>
<!-- Author -->
<p class="lead">
by <a href="#"><?php echo $post_author; ?></a>
</p>
<hr>
<!-- Date/Time -->
<p><?php echo $post_date; ?></p>
<hr>
<!-- Preview Image -->
<img class="img-fluid rounded" src="images/<?php echo $post_image; ?>" alt="">
<!-- Post Content -->
<p class="lead"> <?php echo $post_content; ?></p>
<hr>
<?php
?>
</div>
</div>
</div>
no error i want to add two content in one row.
– Morteza Majnouni
Aug 10 at 7:19
By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.
So, is there any error ? or you just want to share your script with us ?
– Boby
Aug 10 at 7:14