<?php include_once('include/main.inc.php');
$hover = "home";
$homepage = mysqli_query($GLOBALS['dbconn'], "select pageDesc,pageTitle, pageImage, page_keyword, page_metadesc, page_metatitle, pageBanner from static_pages where pageID='1' and status='Y'");
$home_res = mysqli_fetch_array($homepage);
@extract($_REQUEST);
$ca_nam1 = $_REQUEST['cid'];
$ca_nam1 = ucwords(str_replace("-", " ", $cid));
$sql_locas = mysqli_query($GLOBALS['dbconn'], "select locationID from location_tbl where locationName='$ca_nam1'");
$location = mysqli_fetch_array($sql_locas);
$location_id = $location['locationID'];
$category_sub_specific = mysqli_query($GLOBALS['dbconn'], "select location_ids,meta_title,meta_keyword,meta_description,description,short_description from location_content_tbl where category_id='0' AND location_id='$location_id'");
$category_sub_general = mysqli_query($GLOBALS['dbconn'], "select location_ids,meta_title,meta_keyword,meta_description,description,short_description from location_content_tbl where category_id='0' AND location_id='0'");
$content_count = mysqli_num_rows($category_sub_general);
if ($content_count > 0) {
    while ($categorysubdomain = mysqli_fetch_array($category_sub_general)) {
        $locati = explode(",", $categorysubdomain['location_ids']);
        if (in_array($location_id, $locati)) {
            if ($categorysubdomain['meta_title'] != '') {
                $page_metatitle = $categorysubdomain['meta_title'];
            }
            if ($categorysubdomain['meta_keyword'] != '') {
                $page_metakey = $categorysubdomain['meta_keyword'];
            }
            if ($categorysubdomain['meta_description']) {
                $page_metadesc = $categorysubdomain['meta_description'];
            }
            $page_desc = html_entity_decode($categorysubdomain['description']);
        }
    }
    //    specific location content
} else {
    $categorysubdomain = mysqli_fetch_array($category_sub_specific);
    $page_metatitle = $categorysubdomain['meta_title'];
    $page_metakey = $categorysubdomain['meta_keyword'];
    $page_metadesc = $categorysubdomain['meta_description'];
    $page_desc = html_entity_decode($categorysubdomain['description']);
    $page_short_desc = $categorysubdomain['short_description'];
    //    general content
}
$page_desc = str_replace('countryname', $ca_nam1, $page_desc);
$page_desc = str_replace('{location}', $ca_nam1, $page_desc);
$page_desc = str_replace('catname', $pid, $page_desc);
$page_metatitle = str_replace('{location}', $ca_nam1, $page_metatitle);
$page_metakey = str_replace('{location}', $ca_nam1, $page_metakey);
$page_metadesc = str_replace('{location}', $ca_nam1, $page_metadesc);
$home_sub_uncheck_loc = mysqli_query($GLOBALS['dbconn'], "select description,short_description from location_content_tbl where category_id='0' AND location_id='0'");
$home_sub_uncheck_res = mysqli_fetch_array($home_sub_uncheck_loc);
$page_desc1 = $home_sub_uncheck_res['description'];
$page_desc1 = str_replace('{location}', $ca_nam1,  $page_desc1);
if (mysqli_num_rows($sql_locas) > 0) {
} else {
    header("Location: " . site_url);
    exit;
}
$blog = mysqli_query($GLOBALS['dbconn'], "select blogDate,catImage,catName,blogDname,catDesc,blog_written from blog_tbl order by catID DESC  limit 0,3");
?>
<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <?php include "app_top.php"; ?>
</head>

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

    <div class="home_slider">
        <div id="carouselExampleAutoplaying" class="carousel slide carousel-fade" data-bs-ride="carousel" data-bs-interval="3000" data-bs-pause="false">
            <div class="carousel-inner">
                <?php
                $i = 1;
                $sql_banner = mysqli_query($GLOBALS['dbconn'], "Select bannerImage, personName  from banner_tbl where status='Y' order by bannerorder ASC");
                while ($res_banner = mysqli_fetch_array($sql_banner)) {
                ?>
                    <div class="carousel-item <?= $i == 1 ? 'active' : ''; ?>">
                        <picture>
                            <source media="(max-width:650px)" srcset="<?= getImage($res_banner['bannerImage'], 800, 355, $res_banner['personName'], "/uploaded-files/banner-image/"); ?>">
                            <img <?= $i == 1 ? '' : 'loading="lazy"'; ?> src="<?= site_url; ?>/uploaded-files/banner-image/<?= $res_banner['bannerImage']; ?>" alt="<?= $res_banner['personName']; ?> in <?= $ca_nam1; ?>" title="<?= $res_banner['personName']; ?> in <?= $ca_nam1; ?>">
                        </picture>
                    </div>
                <?php $i++;
                } ?>

            </div>
            <button class="carousel-control-prev" type="button" data-bs-target="#carouselExampleAutoplaying" data-bs-slide="prev">
                <span class="carousel-control-prev-icon" aria-hidden="true"></span>
                <span class="visually-hidden">Previous</span>
            </button>
            <button class="carousel-control-next" type="button" data-bs-target="#carouselExampleAutoplaying" data-bs-slide="next">
                <span class="carousel-control-next-icon" aria-hidden="true"></span>
                <span class="visually-hidden">Next</span>
            </button>
        </div>
    </div>
    <section class="welcomeSection">
        <div class="container">
            <div class="welcomeText">
                <h1><span>Best Senior Classroom Furniture in <?= $ca_nam1; ?></span></h1>
                <?php if ($page_desc != '') { ?>
                    <?= html_entity_decode($page_desc); ?>
                <?php } else { ?>
                    <?= html_entity_decode($page_desc1); ?>
                <?php   } ?>
                <a class="read_more" href="<?= site_url; ?>/about-us.htm" title="View More">View More</a>
            </div>
        </div>
    </section>
    <section class="home_featured">
        <div class="container-fluid">
            <div class="title_2">Hot Selling Products</div>
            <p class="text-center">Check out our latest collection of <strong>school furniture</strong> and <strong>Composite Science Lab Setup</strong>.</p>
            <div class="clearfix"></div>
            <div class="categorySlider">
                <div class="swiper-wrapper">
                    <?php
                    $home_cat1 = mysqli_query($GLOBALS['dbconn'], "select catImage, catName, displayName, catDesc, catID from category_tbl where home_category='1' and status='Y' order by homeorder asc limit 0,10");
                    while ($home_cat_res2 = mysqli_fetch_assoc($home_cat1)) {
                        if ($home_cat_res2['catImage'] != '') {
                            $imglink = getImage($home_cat_res2[catImage], 516, 516, $home_cat_res2[catName], "/uploaded-files/category/images/");
                        } else {
                            $imglink = getImage("noimage.png", 516, 516, "noimages", "/uploaded-files/category/images/");
                        }
                    ?>
                        <div class="swiper-slide">
                            <div class="feature_item wow fadeInDown" data-wow-delay=".2s">
                                <a href="<?= site_url; ?>/<?= getValidFileName($ca_nam1); ?>/<?= getValidFileName($home_cat_res2['catName']); ?>.htm" title="<?= $home_cat_res2['displayName']; ?> in <?= $ca_nam1; ?>">
                                    <div class="feature_image">
                                        <div class="image">
                                            <img src="<?= site_url; ?>/designer/images/loader.gif" class="lozad" data-src="<?= $imglink; ?>" alt="<?= $home_cat_res2['displayName']; ?> in <?= $ca_nam1; ?>" title="<?= $home_cat_res2['displayName']; ?> in <?= $ca_nam1; ?>">
                                        </div>
                                    </div>
                                </a>
                                <div class="feature_sec">
                                    <h4 class="title_h3"><a href="<?= site_url; ?>/<?= getValidFileName($ca_nam1); ?>/<?= getValidFileName($home_cat_res2['catName']); ?>.htm" title="<?= $home_cat_res2['displayName']; ?> in <?= $ca_nam1; ?>"><?= $home_cat_res2['displayName']; ?></a></h4>
                                    <a class="read_more" href="<?= site_url; ?>/<?= getValidFileName($ca_nam1); ?>/<?= getValidFileName($home_cat_res2['catName']); ?>.htm" title="View More">View More</a>
                                </div>
                            </div>
                        </div>
                    <?php } ?>
                </div>
                <div class="swiper-pagination"></div>
            </div>
        </div>
    </section>
    <div class="why_choose_us">
        <div class="container">
            <div class="row">
                <div class="col-lg-12 col-md-12 text-center wow zoomIn" data-wow-delay=".1s">
                    <div class="title_2">Why <span>Choose Us</span></div>
                    <p class="whyText">Choose Picano Interio LLP for innovative, durable, and aesthetically pleasing furniture solutions. With a commitment to quality, we transform spaces and exceed expectations. Your satisfaction is our priority.</p>
                </div>
                <div class="clearfix"></div>
                <div class="advantage-list">
                    <div class="row">
                        <div class="col-lg-4 col-md-4 wow fadeInLeft" data-wow-delay=".2s">
                            <div class="number">01</div>
                            <div class="advantage-block">
                                <div class="title3">Exceptional Quality</div>
                                <p> Uncompromising commitment to premium materials and craftsmanship ensures furniture that stands the test of time.</p>
                            </div>
                        </div>
                        <div class="col-lg-4 col-md-4 wow zoomIn" data-wow-delay=".3s">
                            <div class="number">02</div>
                            <div class="advantage-block">
                                <div class="title3">Innovative Designs</div>
                                <p>Stay ahead with our cutting-edge designs, blending functionality and aesthetics for spaces that inspire and impress.</p>
                            </div>
                        </div>
                        <div class="col-lg-4 col-md-4 wow fadeInRight" data-wow-delay=".4s">
                            <div class="number">03</div>
                            <div class="advantage-block">
                                <div class="title3">Customer-Centric Approach</div>
                                <p>Your satisfaction is our priority. We listen, understand, and tailor solutions to meet your unique needs.</p>
                            </div>
                        </div>
                        <div class="col-lg-4 col-md-4 wow fadeInLeft" data-wow-delay=".5s">
                            <div class="number">04</div>
                            <div class="advantage-block">
                                <div class="title3">Diverse Product Range:</div>
                                <p>From classrooms to offices, our extensive product line caters to diverse requirements, ensuring a one-stop solution.</p>
                            </div>
                        </div>
                        <div class="col-lg-4 col-md-4 wow zoomIn" data-wow-delay=".6s">
                            <div class="number">05</div>
                            <div class="advantage-block">
                                <div class="title3">Sustainable Practices:</div>
                                <p>We embrace eco-friendly practices, prioritizing sustainability in our manufacturing processes for a greener future.</p>
                            </div>
                        </div>
                        <div class="col-lg-4 col-md-4 wow fadeInRight" data-wow-delay=".6s">
                            <div class="number">06</div>
                            <div class="advantage-block">
                                <div class="title3">Timely Delivery</div>
                                <p>Count on us for prompt and reliable delivery, ensuring your projects are completed seamlessly and on schedule.</p>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <section class="services-style5-area">
        <div class="container">
            <div class="title_2">Composite Science Lab Setup</div>
            <div class="clearfix"></div>
            <div class="row">
                <?php
                $home_cat11 = mysqli_query($GLOBALS['dbconn'], "select catImage, catName, displayName, catDesc, catID from category_tbl where parentID='4' and status='Y' order by catOrder asc limit 0,6");
                while ($home_cat_res2 = mysqli_fetch_assoc($home_cat11)) {
                    if ($home_cat_res2['catImage'] != '') {
                        $imglink = getImage($home_cat_res2[catImage], 476, 476, $home_cat_res2[catName], "/uploaded-files/category/images/");
                    } else {
                        $imglink = getImage("noimage.png", 476, 476, "noimages", "/uploaded-files/category/images/");
                    }
                    $catIdss = $home_cat_res2['catID'];
                    $sql_content = mysqli_query($dbconn, "select short_description from location_content_tbl where category_id ='$catIdss'");
                    $res_content = mysqli_fetch_array($sql_content);
                    $subcontent_descc = html_entity_decode($res_content['short_description']);
                    $subcontent_desccc = str_replace('{location}', $ca_nam1, $subcontent_descc);
                    $subcontent_descccc = str_replace('catname', $res_cat['catName'], $subcontent_desccc);
                ?>
                    <div class="col-lg-4 col-md-4 wow fadeInLeft" data-wow-delay=".1s">
                        <div class="single-service-style5">
                            <div class="img-holder">
                                <div class="inner">
                                    <img src="<?= $imglink; ?>" alt="<?= $home_cat_res2['displayName']; ?> in <?= $ca_nam1; ?>" title="<?= $home_cat_res2['displayName']; ?> in <?= $ca_nam1; ?>">
                                </div>
                                <div class="overlay-style-two"></div>
                                <div class="text-holder">
                                    <h4><a href="<?= site_url; ?>/<?= getValidFileName($ca_nam1); ?>/<?= getValidFileName($home_cat_res2['catName']); ?>.htm" title="<?= $home_cat_res2['displayName']; ?> in <?= $ca_nam1; ?>"><?= $home_cat_res2['displayName']; ?></a></h4>
                                    <div class="text">
                                        <!-- <span>Untrammelled when we nothing</span> -->
                                        <p><?= substr($subcontent_descccc, 0, 100); ?>...</p>
                                    </div>
                                    <div class="readmore">
                                        <div class="overlay-button">
                                            <a href="<?= site_url; ?>/<?= getValidFileName($ca_nam1); ?>/<?= getValidFileName($home_cat_res2['catName']); ?>.htm" title="View More">View More</a>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                <?php } ?>
            </div>
        </div>
    </section>
    <?php include "app-video.php"; ?>
    <?php include "app_footer_sub.php"; ?>
    <?php include "app_bottom.php"; ?>
</body>

</html>