<?php 
include_once("include/main.inc.php"); 
$hover='blog';
$blog_query = mysqli_query($GLOBALS['dbconn'], "select * from blog_tbl");
?>

<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Blogs- <?=COMPANY_NAME;?> </title>
    <meta name="description" content="Blogs- <?=COMPANY_NAME;?>" />
    <meta name="keywords" content="Blogs- <?=COMPANY_NAME;?>" />
    
    <?php include "app_top.php";?>
</head>

<body>
    <?php include "app_header.php";?>



    <!-- Heading Banner-->
    <div class="heading_banner" style="background-image: url(<?=site_url;?>/designer/images/blog-banner.jpg)">
        <div class="container">
            <div class="row">
                <div class="col-xxl-12 col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12 text-center">
                    <h1 class="cat_title">Our Blogs</h1>
                    <div class="clearfix"></div>
                    <div class="cat_title2">We Are Available For You</div>
                </div>
            </div>
        </div>
    </div>

    <!-- Breadcrumb-->
    <div class="inner_breadcrumb hidden_xs">
        <div class="container">
            <div class="row">
                <div class="col-xxl-12 col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
                    <ul class="breadcrumb">
                        <li><a href="<?site_url;?>" title="Home">Home</a></li>
                        <li class="active">Our Blogs</li>
                    </ul>
                </div>
            </div>
        </div>
    </div>


    <!-- Home About-->
    <section class="blog_page">
        <div class="container">
            <div class="row">
                <div class="col-xxl-9 col-xl-9 col-lg-9 col-md-9 col-sm-9 col-12">
                    <div class="blog_left">
                        <h2>Our Blogs</h2>

                        <div class="row">
                        <?php while ($blog_res = mysqli_fetch_array($blog_query)) { ?>
                            <div class="col-xxl-6 col-xl-6 col-lg-6 col-md-6 col-sm-6 col-12">
                               
                                    <div class="blog_grid">
                                        <a href="<?=site_url;?>/blog/<?=getValidFileName($blog_res['catName']);?>.htm" title="<?=$blog_res['catName'];?>">
                                            <div class="image"><img class="img-responsive" src="<?= getImage($blog_res['catImage'], 426, 548, $blog_res['catName'], "/uploaded-files/blog/images/"); ?>" alt="<?php echo $blog_res['blogDname'];?>" title="<?php echo $blog_res['blogDname'];?>"></div>
                                        </a>
                                        <div class="article_title ">
                                            
                                            <h3 class="text-limit-100px"><a href="<?=site_url;?>/blog/<?=getValidFileName($blog_res['catName']);?>.htm"><?=$blog_res['blogDname'];?></a></h3>
                                            <span class="article_category_name">
                                                <a href="<?=site_url;?>/blog/<?=getValidFileName($blog_res['catName']);?>.htm"><span><i class="fa fa-calendar event-icon"></i> <?=$blog_res['blogDate'];?> </span></a>
                                            </span>
                                        </div>
                                    </div>
                                
                            </div>
<?php } ?>
                           


                        </div>



                    </div>
                </div>

                <div class="col-xxl-3 col-xl-3 col-lg-3 col-md-3 col-sm-3 col-12">
                    <div class="left_sidebar">
                        <div class="left_title1">Popular Post</div>
<?php $blog_query2 = mysqli_query($GLOBALS['dbconn'], "select * from blog_tbl"); 
while ($blog_res2 = mysqli_fetch_array($blog_query2)) {
?>

                        <div class="right_news">
                            <a href="<?=site_url;?>/blog/<?=getValidFileName($blog_res2['catName']);?>.htm">
                                <div class="image">
                                    <img class="img-responsive" src="<?= getImage($blog_res2['catImage'], 274, 352, $blog_res2['catName'], "/uploaded-files/blog/images/"); ?>" alt="Milk man">
                                </div>
                            </a>
                            <h4><a href="<?=site_url;?>/blog/<?=getValidFileName($blog_res2['catName']);?>.htm"><?=$blog_res2['blogDname'];?></a></h4>
                        </div>
                        <?php } ?>

                      
                    </div>
                </div>
            </div>
        </div>
    </section>


    <!-- Home Testimonials -->
    <section class="home_testimonials_webpulse">
    <?php include "testimonial.php";?>
    </section>


    <!-- Home Clients -->
    <!-- <section class="webpulse_home_clients">
    <?php // include "our-clients.php";?>
    </section> -->
    <?php include "app_footer.php";?>
    <?php include "app_bottom.php";?>
</body>

</html>