Uname : Linux V-ShopU01 4.18.0-348.20.1.el8_5.x86_64 #1 SMP Thu Mar 10 20:59:28 UTC 2022 x86_64
Server : Apache/2.4.37 (rocky) OpenSSL/1.1.1k
Whoami : apache
Safe Mode : OFF
DOCUMENT ROOT : /var/www/html/site_shopudietDisable Function :
Path : /var/www/html/site_shopudiet/
Server IP : 65.20.74.164
Client IP : 3.128.78.179
Current File : /var/www/html/site_shopudiet/category_detail.php |
<?php
session_start();
unset($_SESSION['grand_total1']);
unset($_SESSION['coupon']);
unset($_SESSION['discount_rate']);
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Online Organic Grocery Store in Kochi | shopUdiet</title>
<link rel="icon" type="image/png" href="images/favicon.png"/>
<meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=no">
<meta name="description" content="All the products we bring you are 100% Organic Certified. Customers can pick and choose the grocery items for their monthly home requirements from our site.">
<meta name="keywords" content="100% Organic Certified, Organic Store, Grocery store, Kochi Organic Store, Organic products">
<meta name="robots" content="*">
<meta name="viewport" content="initial-scale=1.0, width=device-width">
<link rel="icon" href="#" type="image/x-icon">
<link rel="shortcut icon" href="#" type="image/x-icon">
<!-- CSS Style -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<link rel="stylesheet" type="text/css" href="stylesheet/bootstrap.min.css">
<link rel="stylesheet" type="text/css" href="stylesheet/font-awesome.css" media="all">
<!-- <link rel="stylesheet" type="text/css" href="stylesheet/revslider.css" > -->
<link rel="stylesheet" type="text/css" href="stylesheet/owl.carousel.css">
<!-- <link rel="stylesheet" type="text/css" href="stylesheet/owl.theme.css">
<link rel="stylesheet" type="text/css" href="stylesheet/jquery.bxslider.css"> -->
<link rel="stylesheet" type="text/css" href="stylesheet/jquery.mobile-menu.css">
<link rel="stylesheet" type="text/css" href="stylesheet/style.css" media="all">
<link rel="stylesheet" type="text/css" href="stylesheet/responsive.css" media="all">
<link href="https://fonts.googleapis.com/css?family=Merriweather:300,300i,400,400i,700" rel="stylesheet">
<link href="https://fonts.googleapis.com/css?family=Oswald:300,400,500,600,700" rel="stylesheet">
<link href='http://fonts.googleapis.com/css?family=Open+Sans:700,600,800,400' rel='stylesheet' type='text/css'>
<link href="https://fonts.googleapis.com/css?family=Rubik:400,400i,500,500i,700,700i,900" rel="stylesheet">
<!-- BEGIN GOOGLE ANALYTICS CODEs -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script src="https://code.jquery.com/jquery-3.4.1.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/slick-carousel/1.6.0/slick.js"></script>
<!-- <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script> -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>
<script src="https://ajax.aspnetcdn.com/ajax/jquery.validate/1.9/jquery.validate.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/slick-carousel/1.6.0/slick.js"></script>
<link rel="stylesheet" href="/path/to/flickity.css" media="screen">
<script src="/path/to/flickity.pkgd.min.js"></script>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript">
// $(window).load(function(){
// $('.loader').fadeOut("slow");
// });
$(document).ready(function () {
setTimeout(function(){
$('.loader').fadeOut(100);
}, 2500);
});
</script>
<style>
.prdct_show {
height: 457px;
/*margin-bottom: 23px;*/
margin-top: 17px;
max-height: 464px;
max-width:300px; /* or whatever width you want. */
display: inline-block;
}
.menu-tabbing {
text-align: center;
padding-bottom: 50px;
}
.menu-tabbing ul {
background: #ebebeb;
display: inline-block;
border-radius: 50px;
}
.nav-tabs {
border-bottom: 1px solid #dee2e6;
}
.nav {
display: -ms-flexbox;
display: flex;
-ms-flex-wrap: wrap;
flex-wrap: wrap;
padding-left: 0;
margin-bottom: 0;
list-style: none;
}
ul, li {
padding: 0;
margin: 0;
list-style: none;
}
dl, ol, ul {
margin-top: 0;
margin-bottom: 1rem;
}
* {
box-sizing: border-box;
}
*, ::after, ::before {
box-sizing: border-box;
}
user agent stylesheet
ul {
display: block;
list-style-type: disc;
margin-block-start: 1em;
margin-block-end: 1em;
margin-inline-start: 0px;
margin-inline-end: 0px;
padding-inline-start: 40px;
}
.menu-tabbing ul li {
display: inline-block;
}
.nav > li {
position: inherit;
display: inline-block;
}
.font-weight-bold {
font-weight: 700!important;
}
.text-uppercase {
text-transform: uppercase!important;
}
* {
box-sizing: border-box;
}
.active {
background-color:green;
color:white;
}
.sale-label-org {
margin-left: 3px;
width: 30px;
display: inline-block;
position: absolute;
top: 236px;
line-height: 26px;
z-index: 10;
}
@media (max-width: 560px) and (min-width: 280px) {
.sale-label-org {
top: 152px !important;
}
}
.sort-button {
height:30px;
color:black;
background: #d4cccc;;
border: 1px solid #edeef0;
padding: 5px 20px 4px 20px;
box-shadow: none;
font-size: 15px;
border-radius: 6px;
margin: 0 0 0 5px;
cursor: pointer;
line-height: normal;
}
.sort-button:hover {
color:black;
/*background: #013969;*/
border:1px solid #013969;
}
#sort_container {
padding-left: 20px;
padding-top: 20px;
padding-bottom: 10px;
}
.active-btn {
color:white;
background: #013969;
}
.span-before {
font-size: 18px;
font-weight: 700;
}
.active-btn:hover {
color:white;
background: #013969;
}
.banner-top {
background: #db1e5a;
}
.banner-top .alert {
margin: 0;
background: 0 0;
border: none;
color: #fff;
font-size: 14px;
padding: 15px;
}
.fade.in {
opacity: 1;
}
.p5 {
padding: 5px!important;
}
.alert {
border-radius: 0;
}
.alert-info {
color: #31708f;
background-color: #d9edf7;
border-color: #bce8f1;
}
.alert-dismissable, .alert-dismissible {
padding-right: 35px;
}
.alert {
padding: 15px;
margin-bottom: 20px;
border: 1px solid transparent;
border-radius: 4px;
}
.fade {
opacity: 0;
-webkit-transition: opacity .15s linear;
-o-transition: opacity .15s linear;
transition: opacity .15s linear;
}
</style>
</head>
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-170593298-1"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'UA-170593298-1');
</script>
<body>
<div class="loader">
</div>
<div id="page">
<?php
include('header.php');
?>
<div class="page-heading hidden-xs">
<div class="breadcrumbs">
<div class="container">
<div class="row">
<!--col-xs-12-->
</div>
<!--row-->
</div>
<!--container-->
</div>
<div class="page-title">
<h2></h2>
</div>
</div>
<!--breadcrumbs-->
<!-- BEGIN Main Container col2-left -->
<?php
$name=$_REQUEST['id'];
?>
<style>
/* Slider */
.slick-slide {
margin: 0px 20px;
}
.logo-carousel {
overflow: inherit;
box-shadow: 0 5px 0 rgb(200 200 200 / 20%);
}
.slick-slide img {
width: 75%;
}
.slick-track::before,
.slick-track::after {
display: table;
content: '';
}
.slick-track::after {
clear: both;
}
.slick-track {
padding: 1rem 0;
}
.slick-loading .slick-track {
visibility: hidden;
}
.slick-slide.dragging img {
pointer-events: none;
}
.slick-loading .slick-slide {
visibility: hidden;
}
.slick-arrow {
position: absolute;
top: 50%;
background: url(https://raw.githubusercontent.com/solodev/infinite-logo-carousel/master/images/arrow.svg?sanitize=true) center no-repeat;
color: #013969;
border: none;
width: 3rem;
height: 2rem;
text-indent: -10000px;
margin-top: -16px;
z-index: 99;
}
.slick-arrow.slick-next {
margin-left:10px;
right: 14px;
transform: rotate(180deg);
}
.slick-arrow.slick-prev {
}
/* Media Queries */
@media (max-width: 768px) {
.slick-arrow {
width: 1rem;
height: 1rem;
}
}
/* Media Queries */
@media (max-width: 768px) {
.slick-arrow {
width: 2rem;
height: 2rem;
}
}
/* JsFiddle Example only/don't use */
</style>
<section class="main-container col2-left-layout bounceInUp animated cat_grid">
<!-- For version 1, 2, 3, 8 -->
<!-- For version 1, 2, 3 -->
<div class="container">
<div class="row">
<div class="col-main col-sm-12 product-grid">
<div class="pro-coloumn">
<div class="top-cate" >
<div class="featured-pro container">
<h5 class="cat_head">SHOP BY CATEGORY</h5>
<div class = "row">
<section class="logo-carousel slider">
<?php
include('dbconnect.php');
$sql="select * from category";
$result=mysqli_query($conn,$sql);
while($row = mysqli_fetch_array($result))
{
?>
<div class="slide" style="border: none;"><div>
<a href="category_detail.php?id=<?php echo $row['category_name']?>" title="<?php echo $row['category_name']?> " ><img src="admin/img/<?php echo $row['image']?>" alt="Fresh Organic Mustard Leaves " class="img-responsive cat-img" style="border: none;"></a></div><div class="cat_style" >
<a href="category_detail.php?id=<?php echo $row['category_name']?>" title="<?php echo $row['category_name']?> " class="scroll_slide_name" style="border: none;"><?php echo $row['category_name']?> </a></div>
</div>
<?php } ?>
</section>
</div>
</div>
</div>
<?php
include('dbconnect.php');
$name=$_REQUEST['id'];?>
<?php
$name=$_REQUEST['id'];
// echo $name;
$sqls="select * from category where category_name='$name'";
$results=mysqli_query($conn,$sqls);
while($res = mysqli_fetch_array($results)) {
if($res['message'] !='') {
?>
<div class="banner-top">
<div class="container">
<div class="row">
<div class="alert alert-info alert-dismissible fade in p5" role="alert">
<center style = "padding-left: 15px;padding-right: 15px;">
<?php echo $res['message'];?>
</center>
</div>
</div>
</div>
</div>
<!--<section class = "section-color">
<center> <h4 class="blinking"><?php echo $res['message'];?></h4></center>
</section>-->
<?php } } ?>
<section class="product_grids1">
<div class="container">
<!-- <h4 class="cat_namehead"></h4>-->
<div class="row">
<div id="sort_container">
<span class = "span-before"><?php echo $name;?> ></span><a href = ""><button class="sort-button active-btn" data-index="prod_mart_groceries_products_popularity">All</button></a>
<?php
include('dbconnect.php');
$name=$_REQUEST['id'];
$sql = "select sub_category from category where category_name='$name'";
$result = mysqli_query($conn,$sql);
$sq = mysqli_fetch_array($result);
$d = $sq['sub_category'];
if($d !='') {
$data= explode(',',$d);
for($i=0; $i < count($data);$i++)
{ ?>
<a style="color:black;" href="subcategory_details.php?id=<?php echo $name;?>&cat=<?php echo $data[$i]?>" >
<button class="sort-button" data-index="prod_mart_groceries_products_price_desc"id="subcat<?php echo $data[$i];?>"><?php echo $data[$i];?></button>
</a>
<input type="hidden" value="<?php echo $data[$i];?>" id="subcat<?php echo $data[$i];?>">
<?php } } ?>
</div>
</div>
<div class="row" >
<?php
include('dbconnect.php');
$name=$_REQUEST['id'];
$limit = 20;
if (isset($_GET["page"])) { $page = $_GET["page"]; } else { $page=1; };
$start_from = ($page-1) * $limit;
$squery = "select * from product where category_name='$name' AND status='yes' LIMIT $start_from, $limit";
$result = mysqli_query($conn,$squery);
//$i=mysqli_num_rows($result);
//$j=1;
while( $row = mysqli_fetch_array($result))
{
$price=$row['price'];
if($row['status']=='yes'){
?>
<div class="col-sm-3 col-sm-3 col-xs-6 prdct_show">
<div class="product-grid pro-coloumn1">
<div class="pro-img">
<?php if($row['org_status'] == 'org') { ?><img src="images/shop-new-org (1).png" class="sale-label-org" /> <b><p class="sale-label-org" style="margin-top:4px !important; margin-left:35px !important;">Organic</p></b><?php } ?>
<a href="product-detail.php?id=<?php echo $row['id']?>" title="<?php echo $row['product_name']; ?>" class="product-image"><img src="admin/img/<?php echo $row['file1']?>" alt="<?php echo $row['product_name']; ?>" class=" img-responsive pr0-img" style="width: 100%;">
<?php
if(!empty($row['discount'])){
?>
<div class="sale-label sale-top-left"><?php echo $row['discount'];?>% off</div>
<?php
}
?></a>
<div class="item-title1"><a href="product-detail.php?id=<?php echo $row['id']?>" title="<?php echo $row['product_name'];?> "><?php $in = $row['product_name'];
echo $out = strlen($in) > 20 ? substr($in,0,20)."..." : $in;?> </a> </div>
<div class="item-weight"><a href="product-detail.php?id=<?php echo $row['id']?>" title="<?php echo $row['product_name'];?> "><?php echo $row['weight']?> </a> </div>
<form action="add_multipackagecart.php?id=<?php echo $row['id'] ?>" method="post">
<h4><div class="qunt-ol col-md-6 col-sm-6 col-xs-6"> <div class="def-number-input number-input safari_only">
<a onclick="this.parentNode.querySelector('input[type=number]').stepDown()" class="minus"></a>
<input class="quantity1" min="1" name="quantity" id="qty<?php echo $row['id']?>" value="1" type="number">
<a onclick="this.parentNode.querySelector('input[type=number]').stepUp()" class="plus"></a>
</div></div></h4>
<?php
if(empty($row['discount'])){
?>
<h4><div class="item-price1s col-md-6 col-sm-6 col-xs-6 item-view1s">
<?php if ($row['price']>0) { echo "₹". $row['price']; } ?><br>
<strike style="color: #bbb6b6;"></strike><br class="br">
</div></h4>
<?php
}
else
{
?>
<div class="item-price1s col-md-6 col-sm-6 col-xs-6 hidden-xs">
<?php if ($row['mrp']>0) { echo "₹". $row['mrp']; } ?> <br><strike style="color: #bbb6b6;"><?php if ($row['price']>0) { echo "₹".$row['price'];}?></strike>
</div>
<div class="item-price1s col-md-6 col-sm-6 col-xs-6 hidden-lg hidden-md hidden-sm item_view1">
<?php if ($row['mrp']>0) { echo "₹". $row['mrp']; } ?> <br><strike style="color: #bbb6b6;"><?php if ($row['price']>0) { echo "₹".$row['price'];}?></strike>
</div>
<?php
}
?>
<!-- </div> -->
<div class="add_cart">
<?php
include("dbconnect.php");
$cart_id = $_SESSION['cart_id'];
$id = $row['id'];
$data = mysqli_query($conn,"SELECT * FROM product_cart where prduct_id='$id' AND cart_id='$cart_id'");
if(mysqli_num_rows($data) > 0)
{
?>
<button class="btn btn-carts1"type="button" style="background-color:#df2b27;" onclick = "cart()"><span>VIEW CART</span></button>
<?php } else { ?>
<button class="btn btn-carts1" type="button" id="add<?php echo $row['id']?>" onclick = "add_cart(<?php echo $row['id'];?>)"><span>ADD TO CART</span></button>
<?php } ?></form>
</div>
</div>
</div>
<?php
}
else
{
?>
<div class="col-sm-3 col-sm-3 col-xs-6 prdct_show">
<div class="product-grid pro-coloumn1">
<div class="pro-img">
<a title="<?php echo $row['product_name']; ?>" class="product-image"><img src="admin/img/<?php echo $row['file1']?>" alt="<?php echo $row['product_name']; ?>" class=" img-responsive pr0-img" style="opacity:0.4;width: 100%;">
<div class="centered">Out of Stock</div>
<?php
if(!empty($row['discount'])){
?>
<div class="sale-label sale-top-left"><?php echo $row['discount'];?>% off</div>
<?php
}
?></a>
<div class="item-title1"><a title="<?php echo $row['product_name'];?> "><?php $in = $row['product_name'];
echo $out = strlen($in) > 20 ? substr($in,0,20)."..." : $in;?> </a> </div>
<div class="item-weight"><a title="<?php echo $row['product_name'];?> "><?php echo $row['weight']?> </a> </div>
<form >
<h4><div class="qunt-ol col-md-6 col-sm-6 col-xs-6"> <div class="def-number-input number-input safari_only">
<a onclick="this.parentNode.querySelector('input[type=number]').stepDown()" class="minus"></a>
<input class="quantity1" min="1" name="quantity" value="1" type="number">
<a onclick="this.parentNode.querySelector('input[type=number]').stepUp()" class="plus"></a>
</div></div></h4>
<?php
if(empty($row['discount'])){
?>
<h4><div class="item-price1s col-md-6 col-sm-6 col-xs-6 item-view1s">
<?php if ($row['price']>0) { echo "₹". $row['price']; } ?>
<br><strike style="color: #bbb6b6;"></strike>
</div></h4>
<?php
}
else
{
?>
<div class="item-price1s col-md-6 col-sm-6 col-xs-6 hidden-xs">
<?php if ($row['mrp']>0) { echo "₹". $row['mrp']; } ?> <br><strike style="color: #bbb6b6;"><?php if ($row['price']>0) { echo "₹".$row['price'];}?></strike>
</div>
<div class="item-price1s col-md-6 col-sm-6 col-xs-6 hidden-lg hidden-md hidden-sm item_view1">
<?php if ($row['mrp']>0) { echo "₹". $row['mrp']; } ?> <br><strike style="color: #bbb6b6;"><?php if ($row['price']>0) { echo "₹".$row['price'];}?></strike>
</div>
<?php
}
?>
<!-- </div> -->
<div class="add_cart">
<button class="btn btn-carts1" disabled="disabled" ><span>ADD TO CART</span></button></form>
</div>
</div>
</div>
<?php
}
?>
</div>
<?php }?>
</div>
</div>
<style>
.pagination {
display: inline-block;
}
.pagination a {
color: white;
float: left;
padding: 8px 16px;
text-decoration: none;
transition: background-color .3s;
border: 1px solid #edf3ee;
background: #013969;
}
.pagination a:hover:not(.active) {background-color: #ffd016;}
.item_view1{
padding: 0px 10px 8px 15px;
}
.item-view1s{
padding: 10px 10px 18px 15px;
}
</style>
<?php
$sql = "SELECT COUNT(id) FROM product where category_name='$name' AND status='yes'";
/*echo "$sql"; */
$rs_result = mysqli_query($conn, $sql);
$row = mysqli_fetch_row($rs_result);
$total_records = $row[0];
$total_pages = ceil($total_records / $limit);
$pagLink = "<div class='pagination pull-right '>";
for ($i=1; $i<=$total_pages; $i++) {
$pagLink .= "<a href='category_detail.php?id=$name&page=".$i."'>".$i."</a>";
};
echo $pagLink . "</div>";
?>
</section>
</div>
<!-- ///*///====== End article ========= //*/// -->
</div>
<aside class="col-left sidebar col-sm-3 col-xs-12 col-sm-pull-9 wow bounceInUp animated">
</aside>
<!--col-right sidebar-->
</div>
<!--row-->
</div>
<!--container-->
</section>
<!--main-container col2-left-layout-->
<?php
include('footer.php');
?>
</div>
<!--page-->
<!-- Mobile Menu-->
<?php
include('mobile-menu.php');
?>
<a href="#" id="toTop" style="display: block;"><span class="fa fa-arrow-up"></span></a>
<!-- JavaScript -->
<script src="js/jquery.min.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src="js/common.js"></script>
<script src="js/owl.carousel.min.js"></script>
<!-- script src="js/jquery.bxslider.min.js"></script>
<script src="js/jquery.flexslider.js"></script> -->
<script src="js/jquery.mobile-menu.min.js"></script>
<script type="text/javascript">
function add_cart(id)
{
$(".label_top").text('');
$(".fl-mini-cart-content").text('');
var qty = $("#qty"+id).val();
$(".fix").text('');
$.ajax({
url: 'add_multipackagecart.php',
data: {id:id,qty:qty},
type: 'post',
async: false,
dataType: 'json',
success:function(data){
$("#add"+id).text('View Cart');
/*$("#add"+id).attr('disabled','TRUE');*/
//console.log(data.count);
$(".label_top").text(data.count);
$("#add"+id).css('background-color','#df2b27');
$("#add"+id).css('color','#fff');
$("#add"+id).attr("onclick","cart()");
$(".fl-mini-cart-content").append(data.list);
//console.log(data.fix);
$("div").removeClass("hidden-sm");
$(".fix").append(data.fix);
}
});
}
function cart()
{
window.location.href='cart.php';
//alert('error');
}
</script>
<script >$(document).ready(function(){
$('.customer-logos').slick({
slidesToShow: 6,
slidesToScroll: 4,
autoplay: false,
autoplaySpeed: 1500,
arrows: true,
dots: false,
pauseOnHover: false,
responsive: [{
breakpoint: 768,
settings: {
slidesToShow: 6
}
}, {
breakpoint: 520,
settings: {
slidesToShow: 4
}
}]
});
});
function item_all_select()
{
window.location.reload();
}
$(document).ready(function() {
$('.logo-carousel').slick({
slidesToShow: 7,
slidesToScroll: 4,
autoplay: false,
autoplaySpeed: 1000,
arrows: true,
dots: false,
pauseOnHover: true,
responsive: [{
breakpoint: 768,
settings: {
slidesToShow: 4
}
}, {
breakpoint: 520,
settings: {
slidesToShow: 4
}
}]
});
});
</script>
<style type="text/css">
@media (min-width: 280px) and (max-width: 560px){
.main-container{
padding: 0px;
}
}
</style>
<style type="text/css">
.centered {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
font-size: 18px;
color: #013969;
font-weight: 600;
}
.blinking{
font-size: 29px;
color: #fff;
}
.section-color {
background: #db1e5a;
}
@media (min-width: 280px) and (max-width: 560px){
.blinking{
font-size: 14px;
}
}
</style>
</body>
</html>