<?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,keyword1,keyword2 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,locationName from location_tbl where locationName='$ca_nam1' and status='Y'");
$location = mysqli_fetch_array($sql_locas);
$location_id = $location['locationID'];
$ca_nam1 = $location['locationName'];
$category_sub_specific = mysqli_query($GLOBALS['dbconn'], "select location_ids,meta_title,meta_keyword,meta_description,description,short_description,description2,description3 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,description2,description3 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_metatitle2 = $categorysubdomain['meta_title'];
            }
            if ($categorysubdomain['meta_keyword'] != '') {
                $page_metakey2 = $categorysubdomain['meta_keyword'];
            }
            if ($categorysubdomain['meta_description']) {
                $page_metadesc2 = $categorysubdomain['meta_description'];
            }
            $page_desc = html_entity_decode($categorysubdomain['description']);
            $page_desc1 = html_entity_decode($categorysubdomain['description2']);
            $page_desc2 = html_entity_decode($categorysubdomain['description3']);
        }
    }
    //    specific location content
} else {
    $categorysubdomain = mysqli_fetch_array($category_sub_specific);
    $page_metatitle2 = $categorysubdomain['meta_title'];
    $page_metakey2 = $categorysubdomain['meta_keyword'];
    $page_metadesc2 = $categorysubdomain['meta_description'];
    $page_desc = html_entity_decode($categorysubdomain['description']);
    $page_short_desc = $categorysubdomain['short_description'];
    //    general content
}
if ($home_res['keyword1'] != '' && $home_res['keyword2'] != '') {
    $m_title = "hotkeyword1 Manufacturers in location,hotkeyword2 Wholesale Suppliers, Exporters location";
    $page_metatitle = str_replace('hotkeyword1', $home_res[keyword1], str_replace('hotkeyword2', $home_res[keyword2],  str_replace('location', $ca_nam1, $m_title)));
    $m_keyword = "hotkeyword1 in location, hotkeyword2 in location, hotkeyword1 Manufacturers in location, hotkeyword2 Manufacturers in location, hotkeyword1 Suppliers in location, hotkeyword2 Suppliers in location, hotkeyword1, hotkeyword2";
    $page_metakey = str_replace('hotkeyword1', $home_res[keyword1], str_replace('hotkeyword2', $home_res[keyword2],  str_replace('location', $ca_nam1, $m_keyword)));

    $m_desc = "companyName leading hotkeyword1 Manufacturers in location. Best Quality hotkeyword2 Suppliers in location at Factory Price. Call phone";
    $page_metadesc = str_replace('hotkeyword1', $home_res[keyword1], str_replace('hotkeyword2', $home_res[keyword2], str_replace('companyName', $admin_res[companyName], str_replace('phone', $admin_res[mobile_meta], str_replace('location', $ca_nam1, $m_desc)))));
} else {
    $page_metatitle = $page_metatitle1;
    $page_metakey = $page_metakey1;
    $page_metadesc = $page_metadesc1;
}
$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_desc = str_ireplace('{companyName}', $admin_res['companyName'], $page_desc);
$page_desc1 = str_replace('countryname', $ca_nam1, $page_desc1);
$page_desc1 = str_replace('{location}', $ca_nam1, $page_desc1);
$page_desc1 = str_replace('catname', $pid, $page_desc1);
$page_desc1 = str_ireplace('{companyName}', $admin_res['companyName'], $page_desc1);
$page_desc2 = str_replace('countryname', $ca_nam1, $page_desc2);
$page_desc2 = str_replace('{location}', $ca_nam1, $page_desc2);
$page_desc2 = str_replace('catname', $pid, $page_desc2);
$page_desc2 = str_ireplace('{companyName}', $admin_res['companyName'], $page_desc2);
$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,meta_title,meta_description,meta_keyword,description2,description3 from location_content_tbl where category_id='0' AND location_id='0'");
$home_sub_uncheck_res = mysqli_fetch_array($home_sub_uncheck_loc);
$page_desc_un = $home_sub_uncheck_res['description'];
$page_desc1_un = $home_sub_uncheck_res['description2'];
$page_desc2_un = $home_sub_uncheck_res['description3'];
$page_metatitle1 = $home_sub_uncheck_res['meta_title'];
$page_metakey1 = $home_sub_uncheck_res['meta_keyword'];
$page_metadesc1 = $home_sub_uncheck_res['meta_description'];
$page_desc_un = str_replace('{location}', $ca_nam1,  $page_desc_un);
$page_desc_un = str_ireplace('{companyName}', $admin_res['companyName'], $page_desc_un);
$page_desc1_un = str_replace('{location}', $ca_nam1,  $page_desc1_un);
$page_desc1_un = str_ireplace('{companyName}', $admin_res['companyName'], $page_desc1_un);
$page_desc2_un = str_replace('{location}', $ca_nam1,  $page_desc2_un);
$page_desc2_un = str_ireplace('{companyName}', $admin_res['companyName'], $page_desc2_un);
$page_metatitle1 = str_replace('{location}', $ca_nam1, $page_metatitle1);
$page_metakey1 = str_replace('{location}', $ca_nam1, $page_metakey1);
$page_metadesc1 = str_replace('{location}', $ca_nam1, $page_metadesc1);
$page_metatitle = ($page_metatitle != '') ? $page_metatitle : $page_metatitle1;
$page_metakey = ($page_metakey != '') ? $page_metakey : $page_metakey1;
$page_metadesc = ($page_metadesc != '') ? $page_metadesc : $page_metadesc1;

if (strpos($_SERVER['REQUEST_URI'], "?") !== false) {
    $uri_parts = explode('?', $_SERVER['REQUEST_URI']);
    $linksLoc = $uri_parts[0];
    header("Location: " . site_url . $linksLoc);
    exit;
}

if (mysqli_num_rows($sql_locas) > 0) {
} else {
    header("Location: " . site_url);
    exit;
}

$page_metadesc = str_ireplace('{companyName}', $admin_res['companyName'], $page_metadesc);
?>
<!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="carouselExampleControls" class="carousel slide" data-bs-ride="carousel">
            <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' : ''; ?>">
                        <img fetchpriority="high" width="1920" height="500"
                            src="<?= site_url; ?>/uploaded-files/banner-image/<?= $res_banner['bannerImage']; ?>"
                            alt="<?= $res_banner['personName']; ?> Manufacturers in <?= $ca_nam1; ?>"
                            title="<?= $res_banner['personName']; ?> Manufacturers in <?= $ca_nam1; ?>" class="d-block w-100">
                    </div>
                <?php $i++;
                } ?>

            </div>
            <button class="carousel-control-prev" type="button" data-bs-target="#carouselExampleControls"
                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="#carouselExampleControls"
                data-bs-slide="next">
                <span class="carousel-control-next-icon" aria-hidden="true"></span>
                <span class="visually-hidden">Next</span>
            </button>
        </div>

    </div>

    <div class="ab_tx">
        <div class="container">
            <div class="row">
                <div class="col-lg-7 col-12">
                    <div class="tx_bx">
                        <h1> <span>Diabetic Food in <?= $ca_nam1; ?></span></h1>
                        <div class="ab_con">
                            <?php if ($page_desc != '') { ?>
                                <?= html_entity_decode($page_desc); ?>
                            <?php } else { ?>
                                <?= html_entity_decode($page_desc_un); ?>
                            <?php   } ?>
                            <a href="<?= site_url; ?>/about-us.htm" class="moreBtn" title="Know About Us">Know About
                                Us</a>
                        </div>
                    </div>
                </div>
                <div class="col-lg-5 col-12">
                    <div class="imgs_bx">
                        <div class="img_bx1">
                            <img width="600" height="780" loading="lazy"
                                src="<?= site_url; ?>/designer/images/about/abt3.jpg"
                                alt="Diabetic Food in <?= $ca_nam1; ?>" title="Diabetic Food in <?= $ca_nam1; ?>">
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <div class="webpulse_home_featured">
        <div class="container">
            <div class="tt-bx">
                <div class="tt">Our Low GI <span>Diabetic Food</span></div>
                <p>Indulge in our finest creations! Discover a range of diabetic-friendly delights, from Low GI food to
                    Gluten-Free Dosa Mix. Elevate your health with our carefully crafted and delicious offerings.</p>
            </div>
            <div class="clearfix"></div>
            <div id="featuredProducts" class="owl-carousel">
                <?php
                $home_cat1 = mysqli_query($GLOBALS['dbconn'], "select catImage, catName, displayName, catDesc, catID,catBanner from category_tbl where parentID='1' and status='Y' order by catOrder asc limit 0,6");
                while ($home_cat_res2 = mysqli_fetch_assoc($home_cat1)) {
                    if ($home_cat_res2['catImage'] != '') {
                        $imglink = getImage($home_cat_res2[catImage], 300, 300, $home_cat_res2[catName], "/uploaded-files/category/images/");
                    } else {
                        $imglink = getImage("noimage.jpg", 300, 300, "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);
                    $subcontent_descccc = str_ireplace('{companyName}', $admin_res['companyName'], $subcontent_descccc);
                ?>
                    <div class="productBox">
                        <div class="productImg">
                            <a href="<?= site_url; ?>/<?= getValidFileName($ca_nam1); ?>/<?= getValidFileName($home_cat_res2['catName']); ?>.htm"
                                title="<?= $home_cat_res2['displayName']; ?> Manufacturers in <?= $ca_nam1; ?>">
                                <img loading="lazy" src="<?= $imglink; ?>"
                                    alt="<?= $home_cat_res2['displayName']; ?> Manufacturers in <?= $ca_nam1; ?>"
                                    title="<?= $home_cat_res2['displayName']; ?> Manufacturers in <?= $ca_nam1; ?>" width="300"
                                    height="300">
                            </a>
                            <a href="<?= site_url; ?>/<?= getValidFileName($ca_nam1); ?>/<?= getValidFileName($home_cat_res2['catName']); ?>.htm"
                                class="link"
                                title="<?= $home_cat_res2['displayName']; ?> Manufacturers in <?= $ca_nam1; ?>"><svg
                                    xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor"
                                    class="bi bi-link-45deg" viewBox="0 0 16 16">
                                    <path
                                        d="M4.715 6.542 3.343 7.914a3 3 0 1 0 4.243 4.243l1.828-1.829A3 3 0 0 0 8.586 5.5L8 6.086a1.002 1.002 0 0 0-.154.199 2 2 0 0 1 .861 3.337L6.88 11.45a2 2 0 1 1-2.83-2.83l.793-.792a4.018 4.018 0 0 1-.128-1.287z">
                                    </path>
                                    <path
                                        d="M6.586 4.672A3 3 0 0 0 7.414 9.5l.775-.776a2 2 0 0 1-.896-3.346L9.12 3.55a2 2 0 1 1 2.83 2.83l-.793.792c.112.42.155.855.128 1.287l1.372-1.372a3 3 0 1 0-4.243-4.243L6.586 4.672z">
                                    </path>
                                </svg></a>
                        </div>
                        <div class="productContent">
                            <h4 class="productTitle"><a
                                    href="<?= site_url; ?>/<?= getValidFileName($ca_nam1); ?>/<?= getValidFileName($home_cat_res2['catName']); ?>.htm"
                                    title="<?= $home_cat_res2['displayName']; ?> Manufacturers in <?= $ca_nam1; ?>"><?= $home_cat_res2['displayName']; ?></a>
                            </h4>
                            <!-- <p><?= html_entity_decode(substr($subcontent_descccc, 0, 120)); ?>...</p> -->
                        </div>
                    </div>
                <?php } ?>

            </div>
            <a href="<?= site_url; ?>/<?= getValidFileName($ca_nam1); ?>/diabetic-food.htm" class="moreBtn"
                title="View All Products">View All Products</a>
        </div>
    </div>
    <div class="ab_tx" style="background: url(<?= site_url; ?>/designer/images/bg/pattern_bg.png);">
        <div class="container">
            <div class="row g-4">
                <div class="col-md-4 col-12">
                    <img loading="lazy" src="<?= site_url; ?>/designer/images/about/abt5.jpg"
                        alt="Diabetic Food Manufacturers in <?= $ca_nam1; ?>"
                        title="Diabetic Food Manufacturers in <?= $ca_nam1; ?>" width="531" height="607">
                </div>
                <div class="col-md-8 col-12">
                    <h2>Diabetic Food Manufacturers in <?= $ca_nam1; ?></h2>
                    <?php if ($page_desc1 != '') { ?>
                        <?= html_entity_decode($page_desc1); ?>
                    <?php } else { ?>
                        <?= html_entity_decode($page_desc1_un); ?>
                    <?php   } ?>
                </div>
            </div>
        </div>
    </div>
    <section class="why-choose-us">
        <div class="container">
            <div class="row">
                <div class="image-column col-lg-5 col-12">
                    <div class="inner-column">
                        <figure class="image wow fadeInUp"><img loading="lazy"
                                src="<?= getImage("image-6.jpg", 460, 600, "homeimage", "/designer/images/"); ?>"
                                alt="<?= $admin_res['companyName']; ?>" title="<?= $admin_res['companyName']; ?>"
                                width="460" height="598"></figure>
                    </div>
                </div>

                <div class="features-column col-lg-7 col-12 order-2">
                    <div class="inner-column">
                        <div class="ab_head mb-4">
                            <div class="sub">Why Choose Us</div>
                            <div class="tt">Discover the Reasons below To <span> Choose Us!</span></div>
                        </div>
                        <div class="row align-items-stretch">
                            <div class="col-md-6 col-12 wow fadeInUp">
                                <div class="why-bx">
                                    <div class="ic-bx">
                                        <img src="<?= site_url; ?>/designer/images/icon/lab.png" alt="Lab Approved"
                                            title="Lab Approved" width="128" height="128">
                                    </div>
                                    <div class="tt">Lab Approved</div>
                                    <p>Explore our diabetic-friendly products rigorously tested and approved in
                                        certified laboratories for superior quality.</p>
                                </div>
                            </div>
                            <div class="col-md-6 col-12 wow fadeInUp">
                                <div class="why-bx">
                                    <div class="ic-bx">
                                        <img src="<?= site_url; ?>/designer/images/icon/Healthy.png"
                                            alt="Healthy Ingredients" title="Healthy Ingredients" width="128"
                                            height="128">
                                    </div>
                                    <div class="tt">Healthy Ingredients</div>
                                    <p>Choose us for wholesome diabetic foods crafted with carefully selected,
                                        nutritious ingredients for optimal well-being.</p>
                                </div>
                            </div>
                            <div class="col-md-6 col-12 wow fadeInUp">
                                <div class="why-bx">
                                    <div class="ic-bx">
                                        <img src="<?= site_url; ?>/designer/images/icon/Solutions.png"
                                            alt="Tailored Solutions" title="Tailored Solutions" width="128"
                                            height="128">
                                    </div>
                                    <div class="tt">Tailored Solutions</div>
                                    <p>Discover personalized diabetic food solutions, curated to meet individual
                                        preferences and dietary needs seamlessly.</p>
                                </div>
                            </div>
                            <div class="col-md-6 col-12 wow fadeInUp">
                                <div class="why-bx">
                                    <div class="ic-bx">
                                        <img src="<?= site_url; ?>/designer/images/icon/customer.png"
                                            alt="Customer Satisfaction" title="Customer Satisfaction" width="128"
                                            height="128">
                                    </div>
                                    <div class="tt">Customer Satisfaction</div>
                                    <p>Opt for Sriram Diabetic Foods to experience unparalleled customer satisfaction,
                                        ensuring your health and happiness.</p>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>


            </div>
        </div>
    </section>
    <?php include 'app_certificate.php'; ?>
    <div class="ab_tx" style="background: #fff;">
        <div class="container">
            <div class="row">
                <div class="col-md-8 col-12">
                    <h3>Diabetic Herbs Suppliers in <?= $ca_nam1; ?></h3>
                    <?php if ($page_desc2 != '') { ?>
                        <?= html_entity_decode($page_desc2); ?>
                    <?php } else { ?>
                        <?= html_entity_decode($page_desc2_un); ?>
                    <?php   } ?>
                </div>
                <div class="col-md-4 col-12">
                    <img loading="lazy" src="<?= site_url; ?>/designer/images/about/abt4.jpg"
                        alt="Diabetic Herbs Suppliers in <?= $ca_nam1; ?>"
                        title="Diabetic Herbs Suppliers in <?= $ca_nam1; ?>" width="610" height="800">
                </div>
            </div>
        </div>
    </div>
    <div class="whyChoose">
        <div class="container">
            <div class="tt-bx">
                <div class="tt">What Makes Us The <span>Best In the Industry</span></div>
                <p class="text-dark">Our commitment to excellence, unparalleled expertise, and customer-centric approach
                    distinguish us as the best in the industry. Experience superior quality and service with us.</p>
            </div>
            <div class="row g-0">
                <div class="col-lg-3 col-6 wow fadeInLeft">
                    <div class="count-bx">
                        <div class="ic-bx">
                            <img src="<?= site_url; ?>/designer/images/icon/expertise.png" alt="Year of Expertise"
                                title="Year of Expertise" width="128" height="128">
                        </div>
                        <div class="tx-bx">
                            <div class="coun">
                                <span id="count1">0</span><span>+</span>
                            </div>
                            <p>Year of Expertise</p>
                        </div>
                    </div>
                </div>
                <div class="col-lg-3 col-6 wow fadeInLeft" data-wow-delay=".2s">
                    <div class="count-bx">
                        <div class="ic-bx">
                            <img src="<?= site_url; ?>/designer/images/icon/organic.png" alt="Pure & Organic"
                                title="Pure & Organic" width="128" height="128">
                        </div>
                        <div class="tx-bx">
                            <div class="coun">
                                <span id="count2">0</span><span>%</span>
                            </div>
                            <p>Pure & Organic</p>
                        </div>
                    </div>
                </div>
                <div class="col-lg-3 col-6 wow fadeInLeft" data-wow-delay=".4s">
                    <div class="count-bx">
                        <div class="ic-bx">
                            <img src="<?= site_url; ?>/designer/images/icon/products.png" alt="Quality Products"
                                title="Quality Products" width="128" height="128">
                        </div>
                        <div class="tx-bx">
                            <div class="coun">
                                <span id="count3">0</span><span>+</span>
                            </div>
                            <p>Quality Products</p>
                        </div>
                    </div>
                </div>
                <div class="col-lg-3 col-6 wow fadeInLeft" data-wow-delay=".6s">
                    <div class="count-bx border-0">
                        <div class="ic-bx">
                            <img src="<?= site_url; ?>/designer/images/icon/client.png" alt="Satisfied Customers!"
                                title="Satisfied Customers!" width="128" height="128">
                        </div>
                        <div class="tx-bx">
                            <div class="coun">
                                <span id="count4">0</span><span>%</span>
                            </div>
                            <p>Satisfied Customers!</p>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>



    <?php include 'app_footer_sub.php'; ?>
    <?php include 'app_bottom.php'; ?>
</body>

</html>