Professional Documents
Culture Documents
Final Review
Final Review
VELLORE VIT
JUNE 2021
DECLARATION
I further declare that the work reported in this thesis has not been submitted and
will not be submitted, either in part or in full, for the award of any other degree or
diploma in this institute or any other institute or university.
Place: Vellore
Date: 21/4/2021
K. SHARAN
C. SHANKAR GANESH
P. XAVIER RAJA
CERTIFICATE
The contents of this report have not been submitted and will not be submitted either in
part or in full, for the award of any other degree or diploma in this institute or any
other institute or university. The Project report fulfils the requirements and regulations
of VIT and in my opinion meets the necessary standards for submission.
i
ACKNOWLEDGEMENT
Place: Vellore
Date: 21/4/2021
K. SHARAN
C.SHANKAR GANESH
P. XAVIER RAJA
iii
CONTENTS
CONTENTS.................................................................................................iv
LIST OF FIGURES......................................................................................ix
LIST OF TABLES.....................................................................................xi
CHAPTER 1
1.1 INTRODUCTION……………………………………………………………………7
1.2 OBJECTIVES………………………………………………………………………..7
CHAPTER-2
2.2.1 CUSTOMER………………………………………………………………….10
2.2.2 SYSTEM………………………………………………………………...……10
iv
CHAPTER-3
CHAPTER-4
IMPLEMENTATION OF THE SYSTEM
4.1 CODING ………………………………...……………………………..………….12
4.2 UML DIAGRAM……………………………………………………….………….189
4.2.1 USE CASE DIAGRAM………………………………………….…………..189
4.2.2 ARCHITECTURE DIAGRAM…………………………………..………….189
REFERENCE…………………………………………………………..………………......200
v
LIST OF FIGURES:
HOME PAGE………..………………………………………………….……..13
LOGIN PAGE………………………………………..………………….…….33
SIGN PAGE..………..………………………………………………….……..33
PRODUCT PAGE…………..………………………..………………….…….43
PRODUCT DETAIL………………………………………………………..… 53
CART PAGE…….…..………………………………………………….……..70
PAYMENT DETAIL…………………………………………………………..91
MY ACCOUNT …………………………………………………………...….103
WISHLIST………………………………………………………………...……111
TRACK ORDER……………………………………………………………….121
ADMIN……………………………………………………………………....…132
PAYMENT………………………………………………………………….….148
DATABASE…………………………………………………………….………191
LIST OF TABLES:
1.3 SCOPE
To connect directly to the customer.
Providing information to customers regarding their orders through mail
Customers can review after they bought a product.
7
1.4 SYSTEM DEVELOPMENT
8
1.5 FUNCTIONAL REQUIREMENTS
9
CHAPTER-2
10
2.4 PROPOSED SYSTEM: -
2.4.1 Customers:
2.4.2 System:
The System being a new concept would be useful for conducting direct trade
between customers and manufacturers
Customer satisfaction would result in building goodwill and reputation in
market to increase reliability
Employing better ways for customer satisfaction and customer retention
through quality services and efficient consumer grievance system through
feedback.
2.4.3 ADVANTAGES:-
11
To make the system easily maintainable so that the workers and users of the
system can handle the system satisfactorily with easy and convenience.
CHAPTER-3
1.PC DIGITAL
It displays various games which is available on pc
2.PLAYSTATION
It displays various games which is available on PlayStation
3.XBOX
It displays various games which is available on XBOX
4.CONSOLES
It displays various consoles that are available on market
5.LOGIN/SIGNUP
User can log in to their account by entering their username and password and also,
they can create account if they don’t have
6.CART
In this page it displays what are products that are been added by the customer
7.PAYMENTS
It allows you to enter credit and debit card details to pay the amount for the product
12
CHAPTER-4
4.1 IMPLEMENTATION:
HOME
<?php
session_start();
error_reporting(0);
include('includes/config.php');
$id=intval($_GET['id']);
if(isset($_SESSION['cart'][$id])){
$_SESSION['cart'][$id]['quantity']++;
}else{
$query_p=mysqli_query($con,$sql_p);
if(mysqli_num_rows($query_p)!=0){
$row_p=mysqli_fetch_array($query_p);
}else{
$message="Product ID is invalid";
13
echo "<script type='text/javascript'> document.location ='my-cart.php'; </script>";
?>
<!DOCTYPE html>
<html lang="en">
<head>
<link href='http://fonts.googleapis.com/css?family=Roboto:300,400,500,700'
rel='stylesheet' type='text/css'>
</head>
<style>
14
.product-image:focus div.image img {
transform: scale(1.1);
.image {
overflow: hidden;
background: #f3f3f3;
.product-image:hover,
.product-image:focus {
Ink wishlist {
position : absolute;
left: 20px;
</style>
<body class="cnt-home">
<header class="header-style-1">
<?php include('includes/top-header.php');?>
<?php include('includes/main-header.php');?>
<?php include('includes/menu-bar.php');?>
</header>
15
<div class="body-content outer-top-xs" id="top-banner-and-menu">
<div class="container">
<div class="row">
<div class="full-width-slider">
</div>
</div>
<div class="full-width-slider">
</div>
</div>
<div class="full-width-slider">
</div>
</div>
<div class="full-width-slider">
16
</div>
</div>
</div>
</div>
<?php include('includes/side-menu.php');?>
</div>
<div class="info-boxes-inner">
<div class="row">
<div class="info-box">
<div class="row">
<div class="col-xs-2">
</div>
<div class="col-xs-10">
</div>
</div>
</div>
</div>
17
<div class="info-box">
<div class="row">
<div class="col-xs-2">
</div>
<div class="col-xs-10">
</div>
</div>
</div>
</div>
<div class="info-box">
<div class="row">
<div class="col-xs-2">
</div>
<div class="col-xs-10">
</div>
</div>
</div>
18
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="product-slider">
<?php
while ($row=mysqli_fetch_array($ret))
19
{
?>
<div class="col-sm-8">
<div class="products">
<div class="product">
<div class="product-image">
</div>
</div>
<div class="description"></div>
<div class="product-price">
<span class="price">
20
</div>
</div>
<?php } ?>
</div>
</div>
</div>
</div>
<?php } ?>
</div>
</div>
</div>
<div class="product-slider">
<?php
while ($row=mysqli_fetch_array($ret))
21
?>
<div class="col-sm-8">
<div class="products">
<div class="product">
<div class="product-image">
<div class="image">
</div>
</div>
<div class="description"></div>
<div class="product-price">
<span class="price">
</div>
22
</div>
<?php } ?>
</div>
</div>
</div>
</div>
<?php } ?>
</div>
</div>
</div>
<div class="product-slider">
<?php
while ($row=mysqli_fetch_array($ret))
?>
23
<div class="col-sm-8">
<div class="products">
<div class="product">
<div class="product-image">
<div class="image">
</div>
</div>
<div class="description"></div>
<div class="product-price">
<span class="price">
</div>
</div>
24
<?php if($row['productAvailability']=='In Stock'){?>
<?php } ?>
</div>
</div>
</div>
</div>
<?php } ?>
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<section class="section">
25
<?php
while ($row=mysqli_fetch_array($ret))
?>
<div class="col-sm-8">
<div class="products">
<div class="product">
<div class="product-image">
<div class="image">
</div>
</div>
<div class="description"></div>
<div class="product-price">
26
<span class="price">
</div>
</div>
<?php } ?>
</div>
</div>
</div>
</div>
<?php }?>
</div>
</section>
</div>
<div class="col-md-6">
<section class="section">
<h3 class="section-title">XBox</h3>
27
<div class="owl-carousel homepage-owl-carousel custom-carousel outer-top-xs owl-
theme" data-item="2">
<?php
while ($row=mysqli_fetch_array($ret))
?>
<div class="col-sm-8">
<div class="products">
<div class="product">
<div class="product-image">
<div class="image">
</div>
</div>
28
<div class="description"></div>
<div class="product-price">
<span class="price">
</div>
</div>
<?php } ?>
</div>
</div>
</div>
</div>
<?php }?>
</div>
</section>
</div>
</div>
29
</div>
<h3 class="section-title">HeadPhones</h3>
<?php
while ($row=mysqli_fetch_array($ret))
?>
<div class="item">
<div class="products">
<div class="product">
<div class="product-micro">
<div class="product-image">
<div class="image">
<div class="zoom-overlay"></div>
</a>
</div>
30
</div>
</div>
<div class="product-info">
<div class="product-price">
<span class="price">
</span>
</div>
<?php } ?>
</div>
</div>
</div>
</div>
</div>
31
</div>
</div><?php } ?>
</div>
</section>
</div>
</div>
<?php include('includes/brands-slider.php');?>
<?php include('includes/footer.php');?>
<br>
<script src="assets/js/jquery-1.11.1.min.js"></script>
<script src="assets/js/bootstrap.min.js"></script>
<script src="assets/js/bootstrap-hover-dropdown.min.js"></script>
<script src="assets/js/owl.carousel.min.js"></script>
<script src="assets/js/echo.min.js"></script>
<script src="assets/js/jquery.easing-1.3.min.js"></script>
<script src="assets/js/bootstrap-slider.min.js"></script>
<script src="assets/js/jquery.rateit.min.js"></script>
<script src="assets/js/bootstrap-select.min.js"></script>
<script src="assets/js/wow.min.js"></script>
<script src="assets/js/scripts.js"></script>
<script src="switchstylesheet/switchstylesheet.js"></script>
</body>
</html>
32
Home Page: Fig1
<?php
session_start();
error_reporting(0);
include('includes/config.php');
if(isset($_POST['submit']))
$name=$_POST['fullname'];
$email=$_POST['emailid'];
$contactno=$_POST['contactno'];
$password=md5($_POST['password']);
if($query)
33
{
else{
if(isset($_POST['login']))
$email=$_POST['email'];
$password=md5($_POST['password']);
$num=mysqli_fetch_array($query);
if($num>0)
$extra="index.php";
$_SESSION['login']=$_POST['email'];
$_SESSION['id']=$num['id'];
$_SESSION['username']=$num['name'];
$uip=$_SERVER['REMOTE_ADDR'];
$status=1;
34
$host=$_SERVER['HTTP_HOST'];
$uri=rtrim(dirname($_SERVER['PHP_SELF']),'/\\');
header("location:http://$host$uri/$extra");
exit();
else
$extra="login.php";
$email=$_POST['email'];
$uip=$_SERVER['REMOTE_ADDR'];
$status=0;
$host = $_SERVER['HTTP_HOST'];
$uri = rtrim(dirname($_SERVER['PHP_SELF']),'/\\');
header("location:http://$host$uri/$extra");
exit();
?>
<!DOCTYPE html>
<html lang="en">
35
<head>
<link href='http://fonts.googleapis.com/css?family=Roboto:300,400,500,700'
rel='stylesheet' type='text/css'>
<script type="text/javascript">
function valid()
if(document.register.password.value!= document.register.confirmpassword.value)
document.register.confirmpassword.focus();
return false;
36
return true;
</script>
<script>
function userAvailability() {
$("#loaderIcon").show();
jQuery.ajax({
url: "check_availability.php",
data:'email='+$("#email").val(),
type: "POST",
success:function(data){
$("#user-availability-status1").html(data);
$("#loaderIcon").hide();
},
error:function (){}
});
</script>
</head>
<body class="cnt-home">
<header class="header-style-1">
<?php include('includes/main-header.php');?>
<?php include('includes/menu-bar.php');?>
37
<?php include('includes/top-header.php');?>
</header>
<div class="container">
<div class="breadcrumb">
<div class="container">
<div class="breadcrumb-inner">
<li><a href="index.php">Home</a></li>
</ul>
</div>
</div>
</div>
<div class="row">
<?php
echo htmlentities($_SESSION['errmsg']);
38
?>
<?php
echo htmlentities($_SESSION['errmsg']="");
?>
</span>
<div class="form-group">
</div>
<div class="form-group">
</div>
</div>
</form>
</div>
39
<!-- create a new account -->
<div class="form-group">
</div>
<div class="form-group">
</div>
<div class="form-group">
</div>
<div class="form-group">
40
<input type="password" class="form-control unicase-form-control text-input"
id="password" name="password" required >
</div>
<div class="form-group">
</div>
</form>
<div class="checkbox">
<label class="checkbox">
</label>
<label class="checkbox">
</label>
<label class="checkbox">
</label>
</div>
41
</div>
</div>
<?php include('includes/brands-slider.php');?>
</div>
</div>
<?php include('includes/footer.php');?>
<script src="assets/js/jquery-1.11.1.min.js"></script>
<script src="assets/js/bootstrap.min.js"></script>
<script src="assets/js/bootstrap-hover-dropdown.min.js"></script>
<script src="assets/js/owl.carousel.min.js"></script>
<script src="assets/js/echo.min.js"></script>
<script src="assets/js/jquery.easing-1.3.min.js"></script>
<script src="assets/js/bootstrap-slider.min.js"></script>
<script src="assets/js/jquery.rateit.min.js"></script>
<script src="assets/js/bootstrap-select.min.js"></script>
<script src="assets/js/wow.min.js"></script>
<script src="assets/js/scripts.js"></script>
<script src="switchstylesheet/switchstylesheet.js"></script>
</body>
</html>
42
Sign in and Create Account Page: Fig 2
PRODUCT CATEGORY
<?php
session_start();
error_reporting(0);
include('includes/config.php');
$cid=intval($_GET['cid']);
$id=intval($_GET['id']);
if(isset($_SESSION['cart'][$id])){
$_SESSION['cart'][$id]['quantity']++;
}else{
$query_p=mysqli_query($con,$sql_p);
43
if(mysqli_num_rows($query_p)!=0){
$row_p=mysqli_fetch_array($query_p);
if(strlen($_SESSION['login'])==0)
header('location:login.php');
else
if(strlen($_SESSION['login'])==0)
header('location:login.php');
else
44
mysqli_query($con,"insert into wishlist(userId,productId) values('".
$_SESSION['id']."','".$_GET['pid']."')");
header('location:my-wishlist.php');
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Product Category</title>
<link href='http://fonts.googleapis.com/css?family=Roboto:300,400,500,700'
rel='stylesheet' type='text/css'>
45
<script src="assets/js/html5shiv.js"></script>
<script src="assets/js/respond.min.js"></script>
</head>
<header class="header-style-1">
<?php include('includes/main-header.php');?>
<?php include('includes/menu-bar.php');?>
<?php include('includes/top-header.php');?>
</header>
<body class="cnt-home">
<ul class="nav">
while($row=mysqli_fetch_array($sql))
?>
46
<a href="sub-category.php?scid=<?php echo $row['id'];?>" class="dropdown-
toggle">
<?php }?>
</li>
</ul>
</nav>
</div>
<div class="sidebar-module-container">
<div class="sidebar-filter">
<h4 class="widget-title">Category</h4>
</div>
while($row=mysqli_fetch_array($sql))
?>
<div class="accordion">
<div class="accordion-group">
<div class="accordion-heading">
47
<?php echo $row['categoryName'];?>
</a>
</div>
</div>
</div>
<?php } ?>
</div>
</div>
</div>
</div>
</div>
<div class='col-md-9'>
<div class="item">
<div class="container-fluid">
while($row=mysqli_fetch_array($sql))
?>
</div>
<?php } ?>
48
</div>
</div>
</div>
</div>
<div class="search-result-container">
<div class="row">
<?php
$num=mysqli_num_rows($ret);
if($num>0)
while ($row=mysqli_fetch_array($ret))
{?>
<div class="products">
<div class="product">
<div class="product-image">
<div class="image">
49
</div>
</div>
<div class="description"></div>
<div class="product-price">
<span class="price">
</div>
</div>
<ul class="list-unstyled">
</a>
50
</button>
<?php } ?>
</li>
</ul>
</div>
</div>
</div>
</div>
</div>
<?php } ?>
</div>
</div>
</div>
</div>
</div>
</div></div>
51
<?php include('includes/brands-slider.php');?>
<br>
</br>
</div></div>
<?php include('includes/footer.php');?>
<script src="assets/js/jquery-1.11.1.min.js"></script>
<script src="assets/js/bootstrap.min.js"></script>
<script src="assets/js/bootstrap-hover-dropdown.min.js"></script>
<script src="assets/js/owl.carousel.min.js"></script>
<script src="assets/js/echo.min.js"></script>
<script src="assets/js/jquery.easing-1.3.min.js"></script>
<script src="assets/js/bootstrap-slider.min.js"></script>
<script src="assets/js/jquery.rateit.min.js"></script>
<script src="assets/js/bootstrap-select.min.js"></script>
<script src="assets/js/wow.min.js"></script>
<script src="assets/js/scripts.js"></script>
<script src="switchstylesheet/switchstylesheet.js"></script>
</body>
</html>
52
Product Category Page: Fig 4
PRODUCT DETAIL
<?php
session_start();
error_reporting(0);
include('includes/config.php');
$cid=intval($_GET['cid']);
$id=intval($_GET['id']);
if(isset($_SESSION['cart'][$id])){
$_SESSION['cart'][$id]['quantity']++;
}else{
$query_p=mysqli_query($con,$sql_p);
53
if(mysqli_num_rows($query_p)!=0){
$row_p=mysqli_fetch_array($query_p);
}else{
$message="Product ID is invalid";
$pid=intval($_GET['pid']);
if(strlen($_SESSION['login'])==0)
header('location:login.php');
else
header('location:my-wishlist.php');
54
if(isset($_POST['submit']))
$qty=$_POST['quality'];
$price=$_POST['price'];
$value=$_POST['value'];
$name=$_POST['name'];
$summary=$_POST['summary'];
$review=$_POST['review'];
mysqli_query($con,"insert into
productreviews(productId,quality,price,value,name,summary,review)
values('$pid','$qty','$price','$value','$name','$summary','$review')");
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Product Details</title>
<script src="https://kit.fontawesome.com/e4b9747d10.js"
crossorigin="anonymous"></script>
55
<link rel="stylesheet" href="assets/css/animate.min.css">
<link href='http://fonts.googleapis.com/css?family=Roboto:300,400,500,700'
rel='stylesheet' type='text/css'>
</head>
<header class="header-style-1">
<?php include('includes/main-header.php');?>
<?php include('includes/menu-bar.php');?>
<?php include('includes/top-header.php');?>
</header>
<body class="cnt-home">
<div class='container'>
<div class="sidebar-module-container">
<h3 class="section-title">Category</h3>
<div class="accordion">
while($row=mysqli_fetch_array($sql))
56
{
?>
<div class="accordion-group">
<div class="accordion-heading">
</a>
</div>
</div>
<?php } ?>
</div>
</div>
</div>
<?php
while ($rws=mysqli_fetch_array($ret)) {
?>
<div class="item">
<div class="products">
<div class="hot-deal-wrapper">
<div class="image">
57
<img src="admin/productimages/<?php echo htmlentities($rws['id']);?>/<?php echo
htmlentities($rws['productImage1']);?>" width="200" height="334" alt="">
</div>
</div>
<br>
<div class="product-price">
</span>
</div></div>
</div>
</div>
<?php } ?>
</div></div>
</div>
</div>
<?php
$num=mysqli_num_rows($ret);
58
if($num>0)
while($row=mysqli_fetch_array($ret))
{?>
<div class='col-md-7'>
<div id="owl-single-product">
</a>
</div>
</a>
</div>
59
<div class="" id="slide2">
</a>
</div>
</a>
</div>
</div>
<div id="owl-single-product-thumbnails">
<div class="item">
60
</a>
</div>
<div class="item">
</a>
</div>
<div class="item">
</a>
</div>
</div>
</div>
</div>
</div>
<div class="product-info">
61
<a class="heart" data-toggle="tooltip" data-placement="right" title="Wishlist"
href="product-details.php?pid=<?php echo htmlentities($row['id'])?
>&&action=wishlist">
</a>
$num=mysqli_num_rows($rt);
{?>
<div class="row">
<div class="col-sm-3">
</div>
<div class="col-sm-8">
<div class="reviews">
</div>
</div>
</div></div>
<?php } ?>
<div class="row">
<div class="col-sm-3">
<div class="stock-box">
62
<span class="label">Product Brand :</span>
</div>
</div>
<div class="col-sm-9">
<div class="stock-box">
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-3">
<div class="stock-box">
</div>
</div>
<div class="col-sm-9">
<div class="stock-box">
</div>
</div>
</div></div>
63
<div class="row">
<div class="col-sm-4">
<div class="stock-box">
</div>
</div>
<div class="col-sm-15">
<div class="stock-box">
echo "Free";
else
echo htmlentities($row['shippingCharge']);
?></span>
</div>
</div>
</div></div>
<div class="row">
<div class="col-sm-6">
<div class="price-box">
64
<span class="price" style="color:black;">₹<?php echo
htmlentities($row['productPrice']);?></span>
 
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-7">
<?php } ?>
</div>
</div>
</div>
65
<div class="social-icons">
<ul class="list-inline">
</ul>
</div>
</div>
</div></div>
</div>
<div class="row">
<div class="col-sm-3">
</ul>
</div>
<div class="col-sm-9">
<div class="tab-content">
<div class="product-tab">
</div>
</div>
66
<div id="review" class="tab-pane">
<div class="product-tab">
<div class="product-reviews">
</div>
</div></div></div>
</div></div>
</div>
<?php $cid=$row['category'];
$subcid=$row['subCategory']; ?>
<?php
while($rw=mysqli_fetch_array($qry))
{?>
<div class="products">
<div class="product">
<div class="product-image">
<div class="image">
67
<a href="product-details.php?pid=<?php echo htmlentities($rw['id']);?>"><img
src="assets/images/blank.gif" data-echo="admin/productimages/<?php echo
htmlentities($rw['id']);?>/<?php echo htmlentities($rw['productImage1']);?>"
width="200" height="240" alt=""></a>
</div>
</div>
<div class="description"></div>
<div class="product-price">
<span class="price">
</div></div></div>
</div></div>
<?php } ?>
</div>
</section>
</div></div>
</div>
68
<?php } ?>
</div></div>
</div></div>
</div>
<br>
</br>
<?php include('includes/brands-slider.php');?>
<script src="assets/js/jquery-1.11.1.min.js"></script>
<script src="assets/js/bootstrap.min.js"></script>
<script src="assets/js/bootstrap-hover-dropdown.min.js"></script>
<script src="assets/js/owl.carousel.min.js"></script>
<script src="assets/js/echo.min.js"></script>
<script src="assets/js/jquery.easing-1.3.min.js"></script>
<script src="assets/js/bootstrap-slider.min.js"></script>
<script src="assets/js/jquery.rateit.min.js"></script>
<script src="assets/js/bootstrap-select.min.js"></script>
<script src="assets/js/wow.min.js"></script>
<script src="assets/js/scripts.js"></script>
<script src="switchstylesheet/switchstylesheet.js"></script>
<?php include('includes/footer.php');?>
</body>
</html>
69
Product Detail Fig.5
CART
<?php
session_start();
error_reporting(0);
include('includes/config.php');
if(isset($_POST['submit'])){
if(!empty($_SESSION['cart'])){
if($val==0){
unset($_SESSION['cart'][$key]);
}else{
$_SESSION['cart'][$key]['quantity']=$val;
70
}
if(isset($_POST['remove_code']))
if(!empty($_SESSION['cart'])){
foreach($_POST['remove_code'] as $key){
unset($_SESSION['cart'][$key]);
if(isset($_POST['ordersubmit']))
if(strlen($_SESSION['login'])==0)
header('location:login.php');
else{
$quantity=$_POST['quantity'];
71
$pdd=$_SESSION['pid'];
$value=array_combine($pdd,$quantity);
header('location:payment-method.php');
if(isset($_POST['update']))
$baddress=$_POST['billingaddress'];
$bstate=$_POST['bilingstate'];
$bcity=$_POST['billingcity'];
$bpincode=$_POST['billingpincode'];
if($query)
72
// code for Shipping address updation
if(isset($_POST['shipupdate']))
$saddress=$_POST['shippingaddress'];
$sstate=$_POST['shippingstate'];
$scity=$_POST['shippingcity'];
$spincode=$_POST['shippingpincode'];
if($query)
}?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>My Cart</title>
73
<link href="assets/css/lightbox.css" rel="stylesheet">
<link href='http://fonts.googleapis.com/css?family=Roboto:300,400,500,700'
rel='stylesheet' type='text/css'>
</head>
<body class="cnt-home">
<header class="header-style-1">
<?php include('includes/top-header.php');?>
<?php include('includes/main-header.php');?>
<?php include('includes/menu-bar.php');?>
</header>
<div class="body-content">
<div class="container">
<div class="breadcrumb">
<div class="container">
<div class="breadcrumb-inner">
<li><a href="index.php">Home</a></li>
</ul>
</div></div>
74
</div>
<div class="shopping-cart">
<div class="table-responsive">
<thead>
<tr>
</tr>
</thead> <tfoot>
<tr>
<td colspan="7">
<div class="shopping-cart-btn">
<span class="">
75
<a href="index.php" class="btn btn-upper btn-primary outer-left-xs">Continue
Shopping</a>
</span>
</div>
</td>
</tr>
</tfoot>
<tbody>
<?php
if(!empty($_SESSION['cart'])){
?>
<?php
$pdtid=array();
$query = mysqli_query($con,$sql);
$totalprice=0;
$totalqunty=0;
if(!empty($query)){
while($row = mysqli_fetch_array($query)){
$quantity=$_SESSION['cart'][$row['id']]['quantity'];
$subtotal= $_SESSION['cart'][$row['id']]['quantity']*$row['productPrice'];
76
$totalprice = $totalprice + $subtotal+$row['shippingCharge'];
$_SESSION['qnty']=$totalqunty+=$quantity;
array_push($pdtid,$row['id']);
//print_r($_SESSION['pid'])=$pdtid;exit;
?>
<tr>
<td class="cart-product-name-info">
</a>
$_SESSION['sid']=$pd;
?></a>
<div class="row">
<div class="col-sm-4">
</div>
<div class="col-sm-9">
77
<?php $rt=mysqli_query($con,"select * from productreviews where
productId='$pd'");
$num=mysqli_num_rows($rt);
?>
<div class="reviews">
</div>
<?php } ?>
</div></div></h4>
</div>
</td>
<td class="cart-stock">
</h4>
</td>
<td class="product-quantity">
<div class="quant-input">
<div class="arrows">
</div>
78
<input type="number" value="<?php echo $_SESSION['cart'][$row['id']]
['quantity']; ?>" name="quantity[<?php echo $row['id']; ?>]">
</div>
</td>
</tr>
<?php } }
$_SESSION['pid']=$pdtid;
?>
</tbody>
</table>
</div></div>
<thead>
<tr>
<th>
</th>
79
</tr>
</thead>
<tbody>
<tr>
<td>
<div class="form-group">
<?php
while($row=mysqli_fetch_array($query))
{?>
<div class="form-group">
</div>
<div class="form-group">
</div>
<div class="form-group">
80
<input type="text" class="form-control unicase-form-control text-input"
id="billingcity" name="billingcity" required="required" value="<?php echo
$row['billingCity'];?>" >
</div>
<div class="form-group">
</div>
<?php } ?>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<thead>
<tr>
<th>
81
</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<div class="form-group">
<?php
while($row=mysqli_fetch_array($query))
{?>
<div class="form-group">
</div>
<div class="form-group">
</div>
<div class="form-group">
82
<label class="info-title" for="Billing City">Shipping City <span>*</span></label>
</div>
<div class="form-group">
</div>
<?php } ?>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<thead>
<tr>
<th>
83
<div class="cart-grand-total pull-right">
</div>
</div>
<hr>
</div>
</th>
</tr>
</thead>
<tbody>
<tr>
<td>
</div>
</td>
</tr>
84
</tbody>
</table>
<br>
<?php }?>
</div> </div>
</div>
</form>
</div></div>
<?php include('includes/footer.php');?>
<script src="assets/js/jquery-1.11.1.min.js"></script>
<script src="assets/js/bootstrap.min.js"></script>
<script src="assets/js/bootstrap-hover-dropdown.min.js"></script>
<script src="assets/js/owl.carousel.min.js"></script>
<script src="assets/js/echo.min.js"></script>
<script src="assets/js/jquery.easing-1.3.min.js"></script>
<script src="assets/js/bootstrap-slider.min.js"></script>
<script src="assets/js/jquery.rateit.min.js"></script>
<script src="assets/js/bootstrap-select.min.js"></script>
<script src="assets/js/wow.min.js"></script>
<script src="assets/js/scripts.js"></script>
85
<script src="switchstylesheet/switchstylesheet.js"></script>
</body>
</html>
Cart Fig.6
<?php
session_start();
error_reporting(0);
include('includes/config.php');
if(strlen($_SESSION['login'])==0)
header('location:login.php');
86
}
else{
if (isset($_POST['submit'])) {
unset($_SESSION['cart']);
header('location:payment-detail.php');
}else{
header('location:order-history.php');
}?>
<!DOCTYPE html>
<html lang="en">
<head>
87
<link rel="stylesheet" href="assets/css/bootstrap-select.min.css">
<link href='http://fonts.googleapis.com/css?family=Roboto:300,400,500,700'
rel='stylesheet' type='text/css'>
</head>
<body class="cnt-home">
<header class="header-style-1">
<?php include('includes/top-header.php');?>
<?php include('includes/main-header.php');?>
<?php include('includes/menu-bar.php');?>
</header>
<div class="container">
<div class="breadcrumb">
<div class="container">
<div class="breadcrumb-inner">
<li><a href="home.html">Home</a></li>
</ul>
</div></div>
</div>
<div class="row">
88
<div class="col-md-6">
<div class="panel-heading">
<h4 class="unicase-checkout-title">
</a>
</h4>
</div>
<div class="panel-body">
</form>
</div>
</div></div>
</div></div>
</div></div>
89
<?php echo include('includes/brands-slider.php');?>
</div></div>
<?php include('includes/footer.php');?>
<script src="assets/js/jquery-1.11.1.min.js"></script>
<script src="assets/js/bootstrap.min.js"></script>
<script src="assets/js/bootstrap-hover-dropdown.min.js"></script>
<script src="assets/js/owl.carousel.min.js"></script>
<script src="assets/js/echo.min.js"></script>
<script src="assets/js/jquery.easing-1.3.min.js"></script>
<script src="assets/js/bootstrap-slider.min.js"></script>
<script src="assets/js/jquery.rateit.min.js"></script>
<script src="assets/js/bootstrap-select.min.js"></script>
<script src="assets/js/wow.min.js"></script>
<script src="assets/js/scripts.js"></script>
<script src="switchstylesheet/switchstylesheet.js"></script>
</body>
</html>
<?php } ?>
90
Payment Method Fig.7
PAYMENT DETAIL
<?php
session_start();
error_reporting(0);
include('includes/config.php');
if(isset($_POST['submit']))
if(strlen($_SESSION['login'])==0)
header('location:login.php');
91
}
else{
$cardName=$_POST['cardName'];
$cardNo=$_POST['cardNo'];
$Expiry=$_POST['Expiry'];
$Cvv=($_POST['Cvv']);
$query=mysqli_query($con,"insert into
onlinepayment(userId,cardName,cardNo,Expiry,Cvv) values('".
$_SESSION['id']."','$cardName','$cardNo','$Expiry','$Cvv')");
if($query)
header('location:order-history.php');
else{
}}
}?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Payment Detail</title>
92
<link rel="stylesheet" href="assets/css/owl.carousel.css">
<link href='http://fonts.googleapis.com/css?family=Roboto:300,400,500,700'
rel='stylesheet' type='text/css'>
</head>
<style>
body{
color:black;
.body-content h3 {
font-size: 20px;
font-family: ;
text-align:center;
text-transform:uppercase;
padding-bottom: 14px;
background:black;
padding:15px;
color:#29a329;
93
}
.pay-container {
background-color: white;
border-radius: 3px;
width:50%;
input[type=text] {
width: 100%;
margin-bottom: 20px;
padding: 12px;
border-radius: 3px;
}input[type=date] {
width: 100%;
height:45px;
margin-bottom: 20px;
padding: 12px;
border-radius: 3px;
label {
94
font-size:14px;
font-weight:500;
.icon-container {
margin-bottom: 20px;
padding: 7px 0;
font-size: 24px;
.btn {
background-color: #29a329;
color: black;
padding: 12px;
margin: 10px 0;
border: none;
width: 50%;
border-radius: 3px;
cursor: pointer;
font-size: 17px;
span.price {
float: right;
color: grey;
</style>
95
<header class="header-style-1">
<?php include('includes/main-header.php');?>
]<?php include('includes/menu-bar.php');?>
<?php include('includes/top-header.php');?>
</header>
<body>
<div class="row">
<div class="pay-container">
<form method="post">
<h3>Payment</h3>
<div class="icon-container">
</div>
96
<label for="expiry">Expiry</label>
<label for="cvv">CVV</label>
</div>
</div>
</form>
</div></div>
</div>
<br>
</br>
<?php include('includes/brands-slider.php');?>
</div></div>
</div>
<?php include('includes/footer.php');?>
<script src="assets/js/jquery-1.11.1.min.js"></script>
<script src="assets/js/bootstrap.min.js"></script>
<script src="assets/js/bootstrap-hover-dropdown.min.js"></script>
<script src="assets/js/owl.carousel.min.js"></script>
<script src="assets/js/echo.min.js"></script>
<script src="assets/js/jquery.easing-1.3.min.js"></script>
<script src="assets/js/bootstrap-slider.min.js"></script>
<script src="assets/js/jquery.rateit.min.js"></script>
97
<script type="text/javascript" src="assets/js/lightbox.min.js"></script>
<script src="assets/js/bootstrap-select.min.js"></script>
<script src="assets/js/wow.min.js"></script>
<script src="assets/js/scripts.js"></script>
<script src="switchstylesheet/switchstylesheet.js"></script>
</body>
</html>
ORDER HISTORY
<?php
session_start();
error_reporting(0);
98
include('includes/config.php');
if(strlen($_SESSION['login'])==0)
header('location:login.php');
else{
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Order History</title>
<link href='http://fonts.googleapis.com/css?family=Roboto:300,400,500,700'
rel='stylesheet' type='text/css'>
99
var popUpWin=0;
if(popUpWin)
if(!popUpWin.closed) popUpWin.close();
popUpWin = open(URLStr,'popUpWin',
'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizabl
e=no,copyhistory=yes,width='+600+',height='+600+',left='+left+',
top='+top+',screenX='+left+',screenY='+top+'');
</script>
</head>
<body class="cnt-home">
<header class="header-style-1">
<?php include('includes/top-header.php');?>
<?php include('includes/main-header.php');?>
<?php include('includes/menu-bar.php');?>
</header>
<div class="container">
<div class="breadcrumb">
<div class="container">
<div class="breadcrumb-inner">
100
<ul class="list-inline list-unstyled">
<li><a href="index.php">Home</a></li>
<li><a href="my-cart.php">ShoppingCart</a></li>
</ul>
</div></div>
</div>
<div class="shopping-cart">
<div class="table-responsive">
<thead>
<tr>
101
</tr>
</thead>
<tbody>
$cnt=1;
while($row=mysqli_fetch_array($query))
{?>
<tr>
<td class="cart-product-name-info">
</a>
</div>
</td>
<td class="cart-product-quantity">
102
<?php echo $qty=$row['qty']; ?>
</td>
<td class="track">
Track</td></a>
</tr>
</tbody></table>
</div></div>
</div></div>
</form>
</div></div>
<?php include('includes/footer.php');?>
<script src="assets/js/jquery-1.11.1.min.js"></script>
<script src="assets/js/bootstrap.min.js"></script>
<script src="assets/js/bootstrap-hover-dropdown.min.js"></script>
103
<script src="assets/js/owl.carousel.min.js"></script>
<script src="assets/js/echo.min.js"></script>
<script src="assets/js/jquery.easing-1.3.min.js"></script>
<script src="assets/js/bootstrap-slider.min.js"></script>
<script src="assets/js/jquery.rateit.min.js"></script>
<script src="assets/js/bootstrap-select.min.js"></script>
<script src="assets/js/wow.min.js"></script>
<script src="assets/js/scripts.js"></script>
<script src="switchstylesheet/switchstylesheet.js"></script>
</body>
</html>
<?php } ?>
104
MY ACCOUNT
<?php
session_start();
error_reporting(0);
include('includes/config.php');
if(strlen($_SESSION['login'])==0)
header('location:login.php');
else{
if(isset($_POST['update']))
$name=$_POST['name'];
$contactno=$_POST['contactno'];
if($query)
if(isset($_POST['submit']))
105
$sql=mysqli_query($con,"SELECT password FROM users where
password='".md5($_POST['cpass'])."' && id='".$_SESSION['id']."'");
$num=mysqli_fetch_array($sql);
if($num>0)
else
}?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>My Account</title>
106
<link rel="stylesheet" href="assets/css/animate.min.css">
<link href='http://fonts.googleapis.com/css?family=Roboto:300,400,500,700'
rel='stylesheet' type='text/css'>
<script type="text/javascript">
function valid()
if(document.chngpwd.cpass.value=="")
document.chngpwd.cpass.focus();
return false;
else if(document.chngpwd.newpass.value=="")
document.chngpwd.newpass.focus();
return false;
else if(document.chngpwd.cnfpass.value=="")
107
document.chngpwd.cnfpass.focus();
return false;
document.chngpwd.cnfpass.focus();
return false;
return true;
</script>
</head>
<body class="cnt-home">
<header class="header-style-1">
<?php include('includes/top-header.php');?>
<?php include('includes/main-header.php');?>
<?php include('includes/menu-bar.php');?>
</header>
<div class="container">
<div class="breadcrumb">
<div class="container">
<div class="breadcrumb-inner">
108
<ul class="list-inline list-unstyled">
<li><a href="index.php">Home</a></li>
</ul>
</div>
</div></div>
<div class="row">
<div class="col-md-6">
<div class="panel-heading">
<h4 class="unicase-checkout-title">
<span>1.</span>My Profile
</a>
</h4>
</div>
<div class="panel-body">
<div class="row">
<h4>Personal info</h4>
<?php
109
$query=mysqli_query($con,"select * from users where id='".$_SESSION['id']."'");
while($row=mysqli_fetch_array($query))
{?>
<div class="form-group">
</div>
<div class="form-group">
</div>
<div class="form-group">
</div>
</form>
<?php } ?>
</div></div>
110
</div>
</div></div>
<div class="panel-heading">
<h4 class="unicase-checkout-title">
<span>2.</span>Change Password
</a>
</h4>
</div>
<div class="panel-body">
<div class="form-group">
</div>
<div class="form-group">
111
</div>
<div class="form-group">
</div>
</form>
</div></div></div>
</div></div>
<?php include('includes/myaccount-sidebar.php');?>
</div></div>
<?php include('includes/brands-slider.php');?>
</div></div>
<?php include('includes/footer.php');?>
<script src="assets/js/jquery-1.11.1.min.js"></script>
<script src="assets/js/bootstrap.min.js"></script>
<script src="assets/js/bootstrap-hover-dropdown.min.js"></script>
<script src="assets/js/owl.carousel.min.js"></script>
<script src="assets/js/echo.min.js"></script>
<script src="assets/js/jquery.easing-1.3.min.js"></script>
<script src="assets/js/bootstrap-slider.min.js"></script>
<script src="assets/js/jquery.rateit.min.js"></script>
112
<script type="text/javascript" src="assets/js/lightbox.min.js"></script>
<script src="assets/js/bootstrap-select.min.js"></script>
<script src="assets/js/wow.min.js"></script>
<script src="assets/js/scripts.js"></script>
<script src="switchstylesheet/switchstylesheet.js"></script>
</body>
</html>
<?php } ?>
My Account : Fig 10
WISHLIST
<?php
session_start();
error_reporting(0);
113
include('includes/config.php');
if(strlen($_SESSION['login'])==0)
header('location:login.php');
else{
$wid=intval($_GET['del']);
if(isset($_GET['del']))
$id=intval($_GET['id']);
if(isset($_SESSION['cart'][$id])){
$_SESSION['cart'][$id]['quantity']++;
}else{
$query_p=mysqli_query($con,$sql_p);
if(mysqli_num_rows($query_p)!=0){
$row_p=mysqli_fetch_array($query_p);
header('location:my-wishlist.php');
114
}
else{
$message="Product ID is invalid";
}?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>My Wishlist</title>
]<link href='http://fonts.googleapis.com/css?family=Roboto:300,400,500,700'
rel='stylesheet' type='text/css'>
</head>
<body class="cnt-home">
115
<header class="header-style-1">
<?php include('includes/top-header.php');?>
<?php include('includes/main-header.php');?>
<?php include('includes/menu-bar.php');?>
</header>
<div class="breadcrumb">
<div class="container">
<div class="breadcrumb-inner">
<li><a href="home.html">Home</a></li>
<li class='active'>Wishlish</li>
</ul>
</div></div>
</div>
<div class="container">
<div class="row">
<div class="table-responsive">
<table class="table">
<thead>
<tr>
116
<th colspan="5" class="cart-title">my wishlist</th>
</tr>
</thead>
<tbody>
<?php
$ret=mysqli_query($con,"select products.productName as
pname,products.productName as proid,products.productImage1 as
pimage,products.productPrice as pprice,wishlist.productId as pid,products.
productAvailability as paval,wishlist.id as wid from wishlist join products on
products.id=wishlist.productId where wishlist.userId='".$_SESSION['id']."'");
$num=mysqli_num_rows($ret);
if($num>0)
while ($row=mysqli_fetch_array($ret)) {
?>
<tr>
<td class="col-md-6">
$num=mysqli_num_rows($rt);
{?>
117
<div class="rating">
</div>
<?php } ?>
</td>
<td>
</div>
</td>
<td class="col-md-4">
<h4 style="color:red;">Currently<br>Unavailable</h4>
<?php } ?>
</td>
<td class="col-md-2">
</button>
118
<a href="my-cart-acc.php?page=product&action=add&id=<?php echo $row['pid']; ?
>" class="btn-upper btn btn-primary">Add to cart</a>
<?php } ?>
</td>
</td>
</tr>
<tr>
</tr>
<?php } ?>
</tbody>
</table>
</div></div> </div>
</div>
<?php include('includes/brands-slider.php');?>
</div></div>
<?php include('includes/footer.php');?>
119
<script src="assets/js/jquery-1.11.1.min.js"></script>
<script src="assets/js/bootstrap.min.js"></script>
<script src="assets/js/bootstrap-hover-dropdown.min.js"></script>
<script src="assets/js/owl.carousel.min.js"></script>
<script src="assets/js/echo.min.js"></script>
<script src="assets/js/jquery.easing-1.3.min.js"></script>
<script src="assets/js/bootstrap-slider.min.js"></script>
<script src="assets/js/jquery.rateit.min.js"></script>
<script src="assets/js/bootstrap-select.min.js"></script>
<script src="assets/js/wow.min.js"></script>
<script src="assets/js/scripts.js"></script>
<script src="switchstylesheet/switchstylesheet.js"></script>
</body>
</html>
<?php } ?>
120
Wishlist: Fig 11
TRACK ORDER
<?php
session_start();
error_reporting(0);
include('includes/config.php');
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Track Orders</title>
121
<link rel="stylesheet" href="assets/css/owl.carousel.css">
<link href='http://fonts.googleapis.com/css?family=Roboto:300,400,500,700'
rel='stylesheet' type='text/css'>
</head>
<body class="cnt-home">
<header class="header-style-1">
<?php include('includes/top-header.php');?>
<?php include('includes/main-header.php');?>
<?php include('includes/menu-bar.php');?>
</header>
<div class="container">
<div class="breadcrumb">
<div class="container">
<div class="breadcrumb-inner">
<li><a href="index.php">Home</a></li>
122
</ul>
</div></div>
</div>
<div class="row">
<div class="form-group">
</div>
<div class="form-group">
</div>
</form>
</div> </div>
</div>
123
<?php echo include('includes/brands-slider.php');?>
</div></div>
<?php include('includes/footer.php');?>
<script src="assets/js/jquery-1.11.1.min.js"></script>
<script src="assets/js/bootstrap.min.js"></script>
<script src="assets/js/bootstrap-hover-dropdown.min.js"></script>
<script src="assets/js/owl.carousel.min.js"></script>
<script src="assets/js/echo.min.js"></script>
<script src="assets/js/jquery.easing-1.3.min.js"></script>
<script src="assets/js/bootstrap-slider.min.js"></script>
<script src="assets/js/jquery.rateit.min.js"></script>
<script src="assets/js/bootstrap-select.min.js"></script>
<script src="assets/js/wow.min.js"></script>
<script src="assets/js/scripts.js"></script>
<script src="switchstylesheet/switchstylesheet.js"></script>
</body>
</html>
124
Track Order: Fig 11
<?php
session_start();
error_reporting(0);
include('includes/config.php');
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Order History</title>
125
<link rel="stylesheet" href="assets/css/green.css">
<link href='http://fonts.googleapis.com/css?family=Roboto:300,400,500,700'
rel='stylesheet' type='text/css'>
var popUpWin=0;
if(popUpWin)
if(!popUpWin.closed) popUpWin.close();
popUpWin = open(URLStr,'popUpWin',
'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizabl
e=no,copyhistory=yes,width='+600+',height='+600+',left='+left+',
top='+top+',screenX='+left+',screenY='+top+'');
</script>
126
</head>
<body class="cnt-home">
<header class="header-style-1">
<?php include('includes/top-header.php');?>
<?php include('includes/main-header.php');?>
<?php include('includes/menu-bar.php');?>
</header>
<div class="breadcrumb">
<div class="container">
<div class="breadcrumb-inner">
<li><a href="#">Home</a></li>
</ul>
</div></div>
</div>
<div class="container">
<div class="shopping-cart">
<div class="table-responsive">
127
<thead>
<tr>
</tr>
</thead>
<tbody>
<?php
$orderid=$_POST['orderid'];
$email=$_POST['email'];
$num=mysqli_num_rows($ret);
if($num>0)
$query=mysqli_query($con,"select products.productImage1 as
pimg1,products.productName as pname,orders.productId as opid,orders.quantity as
qty,products.productPrice as pprice,orders.paymentMethod as paym,orders.orderDate
as odate,orders.id as orderid from orders join products on
128
orders.productId=products.id where orders.id='$orderid' and orders.paymentMethod
is not null");
$cnt=1;
while($row=mysqli_fetch_array($query))
{?>
<tr>
<td class="cart-product-name-info">
</a>
</div>
</td>
<td class="cart-product-quantity">
</td>
129
<td class="cart-product-sub-total"><span class="cart-sub-total-price"><?php echo
$row['paym']; ?> </span> </td>
<td class="track">
Track
</a></td>
</tr>
<?php } ?>
</tbody>
</table>
</div></div>
</div></div>
</form>
</div>
</div>
<?php include('includes/footer.php');?>
<script src="assets/js/jquery-1.11.1.min.js"></script>
<script src="assets/js/bootstrap.min.js"></script>
130
<script src="assets/js/bootstrap-hover-dropdown.min.js"></script>
<script src="assets/js/owl.carousel.min.js"></script>
<script src="assets/js/echo.min.js"></script>
<script src="assets/js/jquery.easing-1.3.min.js"></script>
<script src="assets/js/bootstrap-slider.min.js"></script>
<script src="assets/js/jquery.rateit.min.js"></script>
<script src="assets/js/bootstrap-select.min.js"></script>
<script src="assets/js/wow.min.js"></script>
<script src="assets/js/scripts.js"></script>
<script src="switchstylesheet/switchstylesheet.js"></script>
</body>
</html>
131
ADMIN DASHBOARD
LOGIN
<?php
session_start();
error_reporting(0);
include("include/config.php");
if(isset($_POST['submit']))
$username=$_POST['username'];
$password=md5($_POST['password']);
$num=mysqli_fetch_array($ret);
if($num>0)
$extra="Home.php";//
$_SESSION['alogin']=$_POST['username'];
$_SESSION['id']=$num['id'];
$host=$_SERVER['HTTP_HOST'];
$uri=rtrim(dirname($_SERVER['PHP_SELF']),'/\\');
header("location:http://$host$uri/$extra");
exit();
132
else
$extra="index.php";
$host = $_SERVER['HTTP_HOST'];
$uri = rtrim(dirname($_SERVER['PHP_SELF']),'/\\');
header("location:http://$host$uri/$extra");
exit();
}?>
<!DOCTYPE html>
<html lang="en">
<head>
</head>
<style>
.wrapper{
padding:114px;
133
}
</style>
<body>
<div class="navbar-inner">
<div class="container">
</a>
</a>
<li><a href="http://localhost/capstoneproject38/shopping/">
Back to Portal
</a></li>
</ul>
</div></div>
</div></div>
<div class="wrapper">
<div class="container">
<div class="row">
134
<div class="module module-login span4 offset5">
<div class="module-head">
<h3>Sign In</h3>
</div>
<div class="module-body">
<div class="control-group">
</div>
</div>
<div class="control-group">
</div></div>
</div>
<div class="module-foot">
<div class="control-group">
135
</div>
</div></div>
</form>
</div></div>
</div></div>
<?php include('include/footer.php');?>
</body>
</html>
CHANGE PASSWORD
<?php
136
session_start();
include('include/config.php');
if(strlen($_SESSION['alogin'])==0)
header('location:index.php');
else{
if(isset($_POST['submit']))
$num=mysqli_fetch_array($sql);
if($num>0)
else
137
}?>
<!DOCTYPE html>
<html lang="en">
<head>
<script type="text/javascript">
function valid()
if(document.chngpwd.password.value=="")
document.chngpwd.password.focus();
return false;
else if(document.chngpwd.newpassword.value=="")
document.chngpwd.newpassword.focus();
138
return false;
else if(document.chngpwd.confirmpassword.value=="")
document.chngpwd.confirmpassword.focus();
return false;
else if(document.chngpwd.newpassword.value!=
document.chngpwd.confirmpassword.value)
document.chngpwd.confirmpassword.focus();
return false;
return true;
</script>
</head>
<body>
<?php include('include/header.php');?>
<div class="wrapper">
<div class="container">
<div class="row">
<?php include('include/sidebar.php');?>
139
<div class="span9">
<div class="content">
<div class="module">
<div class="module-head">
</div>
<div class="module-body">
<?php if(isset($_POST['submit']))
{?>
</div>
<?php } ?>
<br />
<div class="control-group">
<div class="controls">
</div></div>
<div class="control-group">
140
<label class="control-label" for="basicinput">New Password</label>
<div class="controls">
</div></div>
<div class="control-group">
<div class="controls">
</div></div>
<div class="control-group">
<div class="controls">
</div></div>
</form>
</div></div></div>
</div></div>
</div></div>
<?php include('include/footer.php');?>
</body>
141
</html>
<?php } ?>
ORDER MANAGEMENT
<?php
session_start();
include('include/config.php');
if(strlen($_SESSION['alogin'])==0)
header('location:index.php');
else{
142
?>
<!DOCTYPE html>
<html lang="en">
<head>
var popUpWin=0;
if(popUpWin)
if(!popUpWin.closed) popUpWin.close();
popUpWin = open(URLStr,'popUpWin',
'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizabl
e=no,copyhistory=yes,width='+550+',height='+400+',left='+left+',
top='+top+',screenX='+left+',screenY='+top+'');
</script>
143
</head>
<body>
<?php include('include/header.php');?>
<div class="wrapper">
<div class="container">
<div class="row">
<?php include('include/sidebar.php');?>
<div class="span9">
<div class="content">
<div class="module">
<div class="module-head">
<h3>Delivered Orders</h3>
</div>
<div >
<?php if(isset($_GET['del']))
{?>
</div>
<?php } ?>
<br />
144
<thead>
<tr>
<th>#</th>
<th> Name</th>
<th>Shipping Address</th>
<th>Product </th>
<th>Qty </th>
<th>Amount </th>
<th>Order Date</th>
<th>Action</th>
</tr>
</thead>
<tbody>
<?php
$st='Delivered';
$cnt=1;
while($row=mysqli_fetch_array($query))
145
{?>
<tr>
</td>
</tr>
</tbody>
</table>
</div></div></div>
</div></div>
</div></div>
<?php include('include/footer.php');?>
146
<script src="scripts/jquery-ui-1.10.1.custom.min.js" type="text/javascript"></script>
<script src="scripts/datatables/jquery.dataTables.js"></script>
<script>
$(document).ready(function() {
$('.datatable-1').dataTable();
$('.dataTables_paginate').addClass("btn-group datatable-pagination");
} );
</script>
</body>
<?php } ?>
147
PAYMENT
<?php
session_start();
include('include/config.php');
if(strlen($_SESSION['alogin'])==0)
header('location:index.php');
} ?>
<!DOCTYPE html>
<html lang="en">
<head>
148
<title>Admin|Payment</title>
</head>
<body>
<?php include('include/header.php');?>
<div class="wrapper">
<div class="container">
<div class="row">
<?php include('include/sidebar.php');?>
<div class="span9">
<div class="content">
<div class="module">
<div class="module-head">
<h3>Payment</h3>
</div>
<?php if(isset($_GET['del']))
{?>
149
<button type="button" class="close" data-dismiss="alert">×</button>
</div>
<?php } ?>
<br />
<thead>
<tr>
<th>#</th>
<th> ID</th>
<th>Card Name</th>
<th>Card No</th>
<th>Expiry </th>
<th>Cvv</th>
<th>Order Date</th>
</tr>
</thead>
<tbody>
$cnt=1;
while($row=mysqli_fetch_array($query))
{?>
<tr>
150
<td><?php echo htmlentities($cnt);?></td>
</tr>
</tbody>
</table>
</div></div></div>
</div></div>
</div></div>
<?php include('include/footer.php');?>
<script src="scripts/datatables/jquery.dataTables.js"></script>
<script>
$(document).ready(function() {
$('.datatable-1').dataTable();
$('.dataTables_paginate').addClass("btn-group datatable-pagination");
151
$('.dataTables_paginate > a').wrapInner('<span />');
} );
</script>
</body>
</html>
MANAGE USERS
<?php
session_start();
include('include/config.php');
152
if(strlen($_SESSION['alogin'])==0)
header('location:index.php');
else{
if(isset($_GET['del']))
}?>
<!DOCTYPE html>
<html lang="en">
<head>
</head>
<body>
153
<?php include('include/header.php');?>
<div class="wrapper">
<div class="container">
<div class="row">
<?php include('include/sidebar.php');?>
<div class="span10">
<div class="content">
<div class="module">
<div class="module-head">
<h3>Manage Users</h3>
</div>
<?php if(isset($_GET['del']))
{?>
</div>
<?php } ?>
<br />
<thead>
<tr>
154
<th>#</th>
<th> Name</th>
<th>Email </th>
<th>Contact no</th>
</tr>
</thead>
<tbody>
$cnt=1;
while($row=mysqli_fetch_array($query))
{?>
<tr>
</tr>
155
<?php $cnt=$cnt+1; } ?>
</tbody>
</table>
</div></div></div>
</div></div>
</div></div>
<?php include('include/footer.php');?>
<script src="scripts/datatables/jquery.dataTables.js"></script>
<script>
$(document).ready(function() {
$('.datatable-1').dataTable();
$('.dataTables_paginate').addClass("btn-group datatable-pagination");
} );
</script>
</body>
</html>
156
<?php } ?>
CREATE CATEGORY
<?php
session_start();
include('include/config.php');
if(strlen($_SESSION['alogin'])==0)
header('location:index.php');
else{
if(isset($_POST['submit']))
157
{
$category=$_POST['category'];
$description=$_POST['description'];
if(isset($_GET['del']))
}?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Admin| Category</title>
</head>
<body>
158
<?php include('include/header.php');?>
<div class="wrapper">
<div class="container">
<div class="row">
<?php include('include/sidebar.php');?>
<div class="span9">
<div class="content">
<div class="module">
<div class="module-head">
<h3>Category</h3>
</div>
<div class="module-body">
<?php if(isset($_POST['submit']))
{?>
</div>
<?php } ?>
<?php if(isset($_GET['del']))
{?>
159
<strong>Oh snap!</strong> <?php echo htmlentities($_SESSION['delmsg']);?><?
php echo htmlentities($_SESSION['delmsg']="");?>
</div>
<?php } ?>
<br />
<div class="control-group">
<div class="controls">
</div></div>
<div class="control-group">
<div class="controls">
</div></div>
<div class="control-group">
<div class="controls">
</div></div>
</form>
</div></div>
<div class="module">
160
<div class="module-head">
<h3>Manage Categories</h3>
</div>
<thead>
<tr>
<th>#</th>
<th>Category</th>
<th>Description</th>
<th>Creation date</th>
<th>Update date</th>
<th>Action</th>
</tr>
</thead>
<tbody>
$cnt=1;
while($row=mysqli_fetch_array($query))
{?>
<tr>
161
<td> <?php echo date('M d,Y' ,strtotime($row['creationDate']));?></td>
<td>
</tr>
</table>
</div></div></div>
</div></div>
</div></div>
<?php include('include/footer.php');?>
<script src="scripts/datatables/jquery.dataTables.js"></script>
<script>
$(document).ready(function() {
$('.datatable-1').dataTable();
$('.dataTables_paginate').addClass("btn-group datatable-pagination");
162
$('.dataTables_paginate > a:first-child').append('<i class="icon-chevron-left
shaded"></i>');
} );
</script>
</body>
</html>
<?php } ?>
SUB CATEGORY
<?php
session_start();
163
include('include/config.php');
if(strlen($_SESSION['alogin'])==0)
header('location:index.php');
else{
if(isset($_POST['submit']))
$category=$_POST['category'];
$subcat=$_POST['subcategory'];
if(isset($_GET['del']))
}?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Admin| SubCategory</title>
164
<link type="text/css" href="bootstrap/css/bootstrap.min.css" rel="stylesheet">
</head>
<body>
<?php include('include/header.php');?>
<div class="wrapper">
<div class="container">
<div class="row">
<?php include('include/sidebar.php');?>
<div class="span9">
<div class="content">
<div class="module">
<div class="module-head">
<h3>Sub Category</h3>
</div>
<div class="module-body">
<?php if(isset($_POST['submit']))
{?>
165
<strong>Well done!</strong> <?php echo htmlentities($_SESSION['msg']);?
><?php echo htmlentities($_SESSION['msg']="");?>
</div>
<?php } ?>
<?php if(isset($_GET['del']))
{?>
</div>
<?php } ?>
<div class="control-group">
<div class="controls">
while($row=mysqli_fetch_array($query))
{?>
<?php } ?>
</select>
166
</div></div>
<div class="control-group">
<div class="controls">
</div></div>
<div class="control-group">
<div class="controls">
</div></div>
</form>
</div></div>
<div class="module">
<div class="module-head">
<h3>Sub Category</h3>
</div>
<thead>
<tr>
<th>#</th>
<th>Category</th>
<th>Description</th>
167
<th>Creation date</th>
<th>Last Updated</th>
<th>Action</th>
</tr>
</thead>
<tbody>
<?php $query=mysqli_query($con,"select
subcategory.id,category.categoryName,subcategory.subcategory,subcategory.creation
Date,subcategory.updationDate from subcategory join category on
category.id=subcategory.categoryid");
$cnt=1;
while($row=mysqli_fetch_array($query))
{?>
<tr>
<td>
</tr>
168
<?php $cnt=$cnt+1; } ?>
</table>
</div></div></div>
</div></div>
</div></div>
<?php include('include/footer.php');?>
<script src="scripts/datatables/jquery.dataTables.js"></script>
<script>
$(document).ready(function() {
$('.datatable-1').dataTable();
$('.dataTables_paginate').addClass("btn-group datatable-pagination");
} );
</script>
</body>
</html>
<?php } ?>
169
INSERT PRODUCT
<?php
session_start();
include('include/config.php');
if(strlen($_SESSION['alogin'])==0)
header('location:index.php');
else{
if(isset($_POST['submit']))
$category=$_POST['category'];
170
$subcat=$_POST['subcategory'];
$productname=$_POST['productName'];
$productcompany=$_POST['productCompany'];
$productprice=$_POST['productprice'];
$productpricebd=$_POST['productpricebd'];
$productDetail=$_POST['productDetail'];
$productdescription=$_POST['productDescription'];
$productavailability=$_POST['productAvailability'];
$productimage1=$_FILES["productimage1"]["name"];
$productimage2=$_FILES["productimage2"]["name"];
$productimage3=$_FILES["productimage3"]["name"];
$result=mysqli_fetch_array($query);
$productid=$result['pid']+1;
$dir="productimages/$productid";
if(!is_dir($dir)){
mkdir("productimages/".$productid);
move_uploaded_file($_FILES["productimage1"]["tmp_name"],"productimages/
$productid/".$_FILES["productimage1"]["name"]);
move_uploaded_file($_FILES["productimage2"]["tmp_name"],"productimages/
$productid/".$_FILES["productimage2"]["name"]);
move_uploaded_file($_FILES["productimage3"]["tmp_name"],"productimages/
$productid/".$_FILES["productimage3"]["name"]);
171
$sql=mysqli_query($con,"insert into
products(category,subCategory,productName,productCompany,productPrice,product
Detail,productDescription,productAvailability,productImage1,productImage2,product
Image3,productPriceBeforeDiscount)
values('$category','$subcat','$productname','$productcompany','$productprice','$produ
ctDetail','$productdescription','$productavailability','$productimage1','$productimage
2','$productimage3','$productpricebd')");
}?>
<!DOCTYPE html>
<html lang="en">
<head>
<script
type="text/javascript">bkLib.onDomLoaded(nicEditors.allTextAreas);</script>
<script>
function getSubcat(val) {
$.ajax({
type: "POST",
172
url: "get_subcat.php",
data:'cat_id='+val,
success: function(data){
$("#subcategory").html(data);
});
function selectCountry(val) {
$("#search-box").val(val);
$("#suggesstion-box").hide();
</script>
</head>
<body>
<?php include('include/header.php');?>
<div class="wrapper">
<div class="container">
<div class="row">
<?php include('include/sidebar.php');?>
<div class="span9">
<div class="content">
<div class="module">
<div class="module-head">
173
<h3>Insert Product</h3>
</div>
<div class="module-body">
<?php if(isset($_POST['submit']))
{?>
</div>
<?php } ?>
<?php if(isset($_GET['del']))
{?>
</div>
<?php } ?>
<br />
<div class="control-group">
<div class="controls">
174
<select name="category" class="span8 tip" onChange="getSubcat(this.value);"
required>
while($row=mysqli_fetch_array($query))
{?>
<?php } ?>
</select>
</div></div>
<div class="control-group">
<div class="controls">
</select>
</div></div>
<div class="control-group">
<div class="controls">
</div></div>
<div class="control-group">
175
<div class="controls">
</div></div>
<div class="control-group">
<div class="controls">
</div></div>
<div class="control-group">
<div class="controls">
</div></div>
<div class="control-group">
<div class="controls">
</textarea>
</div>
</div><div class="control-group">
176
<div class="controls">
</textarea>
</div></div>
<div class="control-group">
<div class="controls">
<option value="">Select</option>
</select>
</div></div>
<div class="control-group">
<div class="controls">
</div></div>
<div class="control-group">
<div class="controls">
177
</div></div>
<div class="control-group">
<div class="controls">
</div></div>
<div class="control-group">
<div class="controls">
</div></div>
</form>
</div></div></div>
</div></div>
</div></div>
<?php include('include/footer.php');?>
<script src="scripts/datatables/jquery.dataTables.js"></script>
<script>
$(document).ready(function() {
$('.datatable-1').dataTable();
$('.dataTables_paginate').addClass("btn-group datatable-pagination");
178
$('.dataTables_paginate > a').wrapInner('<span />');
} );
</script>
</body>
</html>
<?php } ?>
MANAGE PRODUCT
<?php
session_start();
179
include('include/config.php');
if(strlen($_SESSION['alogin'])==0)
header('location:index.php');
else{
if(isset($_GET['del']))
}?>
<!DOCTYPE html>
<html lang="en">
<head>
</head>
180
<body>
<?php include('include/header.php');?>
<div class="wrapper">
<div class="container">
<div class="row">
<?php include('include/sidebar.php');?>
<div class="span9">
<div class="content">
<div class="module">
<div class="module-head">
<h3>Manage Products</h3>
</div>
<?php if(isset($_GET['del']))
{?>
</div>
<?php } ?>
<br />
<thead>
181
<tr>
<th>#</th>
<th>Product Name</th>
<th>Category </th>
<th>Subcategory</th>
<th>Company Name</th>
<th>Action</th>
</tr>
</thead>
<tbody>
<?php $query=mysqli_query($con,"select
products.*,category.categoryName,subcategory.subcategory from products join
category on category.id=products.category join subcategory on
subcategory.id=products.subCategory");
$cnt=1;
while($row=mysqli_fetch_array($query))
{?>
<tr>
182
<td>
</tr>
</table>
</div></div></div>
</div></div>
</div></div>
<?php include('include/footer.php');?>
<script src="scripts/datatables/jquery.dataTables.js"></script>
<script>
$(document).ready(function() {
$('.datatable-1').dataTable();
$('.dataTables_paginate').addClass("btn-group datatable-pagination");
183
$('.dataTables_paginate > a:last-child').append('<i class="icon-chevron-right
shaded"></i>');
} );
</script>
</body>
</html>
<?php } ?>
<?php
session_start();
include('include/config.php');
if(strlen($_SESSION['alogin'])==0)
184
header('location:index.php');
else{
?>
<!DOCTYPE html>
<html lang="en">
<head>
</head>
<body>
<?php include('include/header.php');?>
<div class="wrapper">
<div class="container">
<div class="row">
<?php include('include/sidebar.php');?>
<div class="span9">
<div class="content">
<div class="module">
185
<div class="module-head">
</div>
<thead>
<tr>
<th>#</th>
<th>User ID </th>
<th>Login Time</th>
<th>Status </th>
</tr>
</thead>
<tbody>
$cnt=1;
while($row=mysqli_fetch_array($query))
{?>
<tr>
186
<td> <?php echo htmlentities($row['loginTime']);?></td>
<td><?php $st=$row['status'];
if($st==1)
echo "Successfull";
else
echo "Failed";
}?></td>
</table>
</div></div></div>
</div></div>
</div></div>
<?php include('include/footer.php');?>
<script src="scripts/datatables/jquery.dataTables.js"></script>
<script>
$(document).ready(function() {
187
$('.datatable-1').dataTable();
$('.dataTables_paginate').addClass("btn-group datatable-pagination");
} );
</script>
</body>
</html>
<?php } ?>
188
DATABASE
189
4.2 UML DIAGRAM
190
4.2.2 ARCHITECTURE DIAGRAM
FLOW CHART
191
4.3 TEST CASES:
192
Unit testing involves the design of test cases that validate that the internal
program logic is functioning properly, and that program inputs produce valid outputs.
All decision branches and internal code flow should be validated. It is the testing of
individual software units of the application .it is done after the completion of an
individual unit before integration. This is a structural testing, that relies on knowledge
of its construction and is invasive. Unit tests perform basic tests at component level
and test a specific business process, application, and/or system configuration. Unit
tests ensure that each unique path of a business process performs accurately to the
documented specifications and contains clearly defined inputs and expected results.
Unit testing is usually conducted as part of a combined code and unit test
phase of the software lifecycle, although it is not uncommon for coding and unit
testing to be conducted as two distinct phases.
193
Username: Phone no. xaviermax07
xavier 4. Enter valid @gmail.com
Password: password Phone no:
xavier 123 5.Click on 1234567890
2 Email: sign up button
xaviermax0
7@gmail.co 1. Don’t Enter Username: To show an To show an Sign up Pass
m username error error attempt
Phone no: 2.Enter valid Password: “please enter “please stopped
1234567890 email xavier 123 username” enter
3. Enter valid Email: username”
Phone no. xaviermax07
4. Enter valid @gmail.com
password Phone no:
5.Click on 1234567890
sign up button
1. Enter valid Username: To show an To show an Sign up Pass
username xavier error error attempt
2.Don’t Enter Password: “please enter “please stopped
valid email xavier 123 valid mail id” enter valid
3. Enter valid Email: mail id”
Phone no.
4. Enter valid Phone no:
password 1234567890
5.Click on
sign up button
1.Enter name Name: Mail Sent. Mail Sent. Mail Pass
2.Enter mail Sharan Thank you Thank you successfully
id Mail id: Sent
3.Enter phone xyz@gmail.
no. com
4.Enter Phone
message no:12345678
5.Click on 90
submit button Message:
Check the hello
functionalit
3 y of contact 1. Don’t Enter Name: To show an To show an Mail doesn’t Pass
us to send name error error Sent
mail 2.Enter mail Mail id: “enter name” “enter
id xyz@gmail. name”
3.Enter phone com
no. Phone
4.Enter no:12345678
message 90
5. Enter Message:
message hello
6.Click on
submit button
1.Enter name Name: To show an To show an Mail doesn’t Pass
194
2.Enter mail Sharan error error Sent
id Mail id: “enter “enter
3.Enter phone xyz@gmail. message” message”
no. com
4. Don’t Phone
message no:12345678
6.Click on 90
submit button Message:
Customer:
S.No Action Inputs Expected Actual Test Test
Output Output Result Comments
1. Launch localhost: Index page Index page Pass Launch
website successful
195
4. Enter valid Alert Alert Pass Invalid
Username Admin ID: xavier message. The message the Login
and invalid Password: xavier password password attempt
Password 2123 that you’ve that you’ve stopped
and hit entered is entered is
login Click incorrect. incorrect.
button Login
5. Select sign Enter name, It will go to It will go to Pass Navigate to
up in the phone no, login page login page login page
login page email id,
password click sign
up
6. Select pc It will It will Pass Navigate to
digital in Click display all display all pc digital
navigation pc digital types of pc types of pc page
bar games that games that
are available. are
available.
7. Select It will It will Pass Navigate to
PlayStation Click display display PlayStation
5 in PlayStation 5 in PlayStation 5 PlayStation 5 page.
consoles consoles drop down games 5 games
navigation tab in navigation bar
bar
8. Select cart It will It will Pass Navigate to
in Click display the display the the cart page
navigation Cart icon products that products
bar customer that
want to buy customer
want to buy
9. Select the Click add to cart Product Product Pass Navigate to
product icon on the product should be should be the cart page
and click added in the added in the
add to cart cart cart
10. Select Click check out in Check out Check out Pass Navigate to
check out the cart page should be should be the check
in cart page displayed displayed out page
196
CHAPTER-5
5.1 CONCLUSION.
Technology has made significant progress over the years to provide consumers a
better online shopping experience and will continue to do so for years to come. With
the rapid growth of products and brands, people have speculated that online shopping
will overtake in-store shopping. While this has been the case in some areas, there is
still demand for offline stores in market areas where the consumer feels more
comfortable seeing and touching the product being bought. However, the availability
of online shopping has produced a more educated consumer that can shop around with
relative ease without having to spend a large amount of time. In exchange, online
shopping has opened up doors to many small retailers that would never be in business
if they had to incur the high cost of owning a offline store. At the end, it has been a
win-win situation for both consumer and sellers.
Future plans for online phoenix gaming and accessories portal is to develop
search products for the customers so it will be much easier to the people to buy their
desired products quicky. and to add many products to the customer
197
6.1 REFERENCE:-
198