/
home
/
u775757334
/
domains
/
civicwelllife.com
/
public_html
/
include
/
/home/u775757334/domains/civicwelllife.com/public_html/include
mkdir
upload
Name
Size
Mode
Actions
about1.php
1746
0644
edit
dl
rm
about2.php
3128
0644
edit
dl
rm
blog-section.php
8307
0644
edit
dl
rm
category-list.php
5334
0644
edit
dl
rm
category-wise-product.php
4868
0644
edit
dl
rm
category.php
2107
0644
edit
dl
rm
client-section.php
2156
0644
edit
dl
rm
cta-banner.php
405
0644
edit
dl
rm
cta-section-1.php
1180
0644
edit
dl
rm
cta-section.php
1165
0644
edit
dl
rm
customer-menu.php
382
0644
edit
dl
rm
day-offer.php
13055
0644
edit
dl
rm
doctor-menu.php
1478
0644
edit
dl
rm
footer-file.php
1779
0644
edit
dl
rm
footer-tab.php
1928
0644
edit
dl
rm
footer.php
11953
0644
edit
dl
rm
header-file.php
658
0644
edit
dl
rm
header-top.php
4157
0644
edit
dl
rm
header.php
19312
0644
edit
dl
rm
impact-section.php
2841
0644
edit
dl
rm
mobile-category.php
1292
0644
edit
dl
rm
mobile-menu.php
8536
0644
edit
dl
rm
model.php
49991
0644
edit
dl
rm
offer.php
2821
0644
edit
dl
rm
product-slide.php
7439
0644
edit
dl
rm
related-product.php
11034
0644
edit
dl
rm
shopping-cart.php
1938
0644
edit
dl
rm
slider.php
2252
0644
edit
dl
rm
testimonial.php
2023
0644
edit
dl
rm
trust-section.php
3902
0644
edit
dl
rm
video-section.php
4045
0644
edit
dl
rm
yt-section.php
4945
0644
edit
dl
rm
Edit:
/home/u775757334/domains/civicwelllife.com/public_html/include/blog-section.php
(8307B)
<?php $home_sql = mysqli_query($conn, " SELECT b.*, b.image1 AS blog_image, d.id AS doctor_id, -- ✅ ADD THIS d.name AS doctor_name, d.experience, d.image1 AS doctor_image, d.eduaction FROM tbl_blog b LEFT JOIN tbl_doctor_registration d ON b.doctor_id = d.id ORDER BY b.id DESC "); $home_blogs = []; while ($row = mysqli_fetch_assoc($home_sql)) { $row['link'] = "blog-details.php?blog_id=" . $row['id']; // ya slug use karna ho to bata dena $row['blog_image'] = "media/image/" . $row['blog_image']; $home_blogs[] = $row; } ?> <section class="home-blog-section py-5"> <div class="container"> <div class="home-blog-head"> <div> <span class="home-blog-mini-title">Health Articles</span> <h2 class="home-blog-title">Latest Doctor Blogs</h2> <p class="home-blog-subtitle"> Read expert health tips, wellness advice, and ayurvedic guidance from our experienced doctors. </p> </div> <div> <a href="doctor-blog.php" class="home-blog-view-all">View All Blogs</a> </div> </div> <div class="row g-4 mt-1"> <?php foreach ($home_blogs as $blog): ?> <div class="col-md-6 col-lg-4"> <div class="home-blog-card h-100"> <a href="<?= $blog['link']; ?>" class="home-blog-img-wrap"> <img src="<?= $blog['blog_image']; ?>" alt="<?= $blog['heading']; ?>" class="home-blog-img"> </a> <div class="home-blog-content"> <h3 class="home-blog-card-title"> <a href="<?= $blog['link']; ?>"> <?= $blog['heading']; ?> </a> </h3> <p class="home-blog-card-desc"> <?= $blog['short_description']; ?> </p> <div class="home-blog-doctor"> <div class="home-blog-doctor-left"> <div class="home-blog-avatar"> <?= !empty($blog['doctor_name']) ? strtoupper(substr($blog['doctor_name'], 0, 1)) : 'D'; ?> </div> <div> <a href="doctor-profile.php?doctor_id=<?= $blog['doctor_id']; ?>" style="text-decoration:none;color:inherit;"> <h6 class="mb-1"> <?= $blog['doctor_name'] ?? 'Unknown Doctor'; ?> </h6> </a> <p class="mb-0"> <?= $blog['eduaction'] ?? ''; ?> </p> </div> </div> <span class="home-blog-exp"> <?= $blog['experience'] ?? ''; ?> </span> </div> <a href="<?= $blog['link']; ?>" class="home-blog-read-btn"> Read More <i class="bi bi-arrow-right"></i> </a> </div> </div> </div> <?php endforeach; ?> </div> </div> </section> <style> .home-blog-section { background: linear-gradient(180deg, #f8fbff 0%, #eef4ff 100%); } .home-blog-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-bottom: 10px; } .home-blog-mini-title { display: inline-block; padding: 7px 14px; border-radius: 30px; background: #edf4ff; color: #2446c6; font-size: 13px; font-weight: 700; margin-bottom: 10px; } .home-blog-title { font-size: 34px; font-weight: 800; color: #111827; margin-bottom: 8px; } .home-blog-subtitle { max-width: 700px; color: #667085; font-size: 15px; line-height: 1.8; margin-bottom: 0; } .home-blog-view-all { display: inline-block; padding: 12px 20px; border-radius: 12px; background: #2446c6; color: #fff; text-decoration: none; font-weight: 700; } .home-blog-view-all:hover { color: #fff; background: #1d39a8; } .home-blog-card { background: #fff; border-radius: 20px; overflow: hidden; border: 1px solid #e8efff; box-shadow: 0 10px 30px rgba(34, 64, 154, 0.08); transition: 0.3s ease; } .home-blog-card:hover { transform: translateY(-4px); box-shadow: 0 16px 38px rgba(34, 64, 154, 0.12); } .home-blog-img-wrap { display: block; overflow: hidden; } .home-blog-img { width: 100%; height: 240px; object-fit: cover; display: block; } .home-blog-content { padding: 20px; } .home-blog-card-title { font-size: 20px; font-weight: 700; line-height: 1.5; margin-bottom: 10px; } .home-blog-card-title a { color: #111827; text-decoration: none; } .home-blog-card-title a:hover { color: #2446c6; } .home-blog-card-desc { color: #667085; font-size: 14px; line-height: 1.8; min-height: 75px; margin-bottom: 6px; } .home-blog-doctor { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; background: #f8faff; border: 1px solid #e8efff; border-radius: 14px; padding: 14px; } .home-blog-doctor-left { display: flex; align-items: center; gap: 12px; } .home-blog-avatar { width: 46px; height: 46px; border-radius: 50%; background: linear-gradient(135deg, #2446c6 0%, #4f74ff 100%); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 18px; font-weight: 700; flex-shrink: 0; } .home-blog-doctor-left h6 { font-size: 15px; font-weight: 700; color: #111827; } .home-blog-doctor-left p { font-size: 13px; color: #667085; } .home-blog-exp { background: #edf4ff; color: #2446c6; padding: 8px 12px; border-radius: 30px; font-size: 12px; font-weight: 700; white-space: nowrap; } .home-blog-read-btn { margin-top: 16px; display: inline-flex; align-items: center; gap: 8px; color: #2446c6; text-decoration: none; font-size: 14px; font-weight: 700; } .home-blog-read-btn:hover { color: #1d39a8; } @media (max-width: 767px) { .home-blog-title { font-size: 26px; } .home-blog-img { height: 220px; } .home-blog-card-desc { min-height: auto; } .home-blog-content { padding: 16px; } } </style>
Save
cmd:
run