Amani: "E-Shop (An Online Shopping Cart) "
Amani: "E-Shop (An Online Shopping Cart) "
Amani: "E-Shop (An Online Shopping Cart) "
(APPROVED BY AICTE & AFFILITED TO U.P. TECHNICAL UNIVERSITY LUCKNOW, CODE 815)
PROJECT REPORT
ON
Guided by:
Mr. Mohd. Shahnawaz
Ms. Ekta Rani
Submitted to:
Mr. Mohd. Shahnawaz
“Head of Department of Computer Science & Engineering”
Submitted by:
NEERU RANI
Roll No: 1481510003
1
DECLARATION
I hereby declare that this project work entitle “e-Shop (An Online Shopping
Cart)”submitted to Amani Group Of Institutions (A.P.J. Abdul Kalam
Technical University, Uttar Pradesh, Lucknow) for the award of (B.Tech),
has been successfully carried out by me under the kind guidance of Prof.
Mr. Mohd. Shahnawaz.
2
Acknowledgement
The satisfaction that accompanies that the successful completion of any task would be
incomplete without the mention of people whose ceaseless cooperation made it possible,
whose constant guidance and encouragement crown all efforts with success.
We are grateful to our project guides Mr. Mohd. Shahnawazand Ms. Ekta Rani for the
guidance, inspiration and constructive suggestions that helpful us in the preparation of this
project.
We also thank our colleagues who have helped in successful completion of the project.
NEERU RANI
3
Certificate
This is to certified that Ms.NEERU RANI, a student of B. Tech 4th year of Computer Science
She has submitted her project report for the partial fulfillment of the Degree of Bachelor of
4
INDEX
Introduction
Analysis
Design
Coding
Testing
Pert Chart
Gantt Chart
Bibliography
Glossary
5
INTRODUCTION
6
Our project is an e-commerce application where we have a concept of shopping cart.
It is an online store for buying and selling goods—a concept that has grown in leaps and bounds over the
last eight years or so and has taken shopping for goods to a completely new level of automation.
Needless to say, the process of order delivery is manual.
The store has collection for handbags, clothing, sunglasses and art glass. The price of products is varied
and so are the brands of products. The price is specified in dollars and there are also shipping charges for
shipping the product at specified address.
1.
Objective:
E-commerce applications help businesses automate their order fulfillment apart from globalizing their
sales rather than sticking to a geographical location.
This helps them to reach out to more customers and enhance their business.
Today, almost every business that exists is either online or on the way to being online. All that the
consumer needs is to have an Internet connection, and they are ready to buy their products online.
7
SYSTEM ANALYSIS
8
Identification of need :
The need of application aroused as usage of Internet increased. The entrepreneurs felt the need to expand their
businesses. The growing popularity and ease of accessing Internet content became their medium of expanding
business.
Thus need was identified by entrepreneurs as well as customers who wished to shop sitting at home and get the
products delivered at home.
The need also came from brands like Amazon, E-bay etc. to sell their products across world by crossing
geographical barriers.
All these circumstances led to a new kind of business i.e. online business known as E-commerce.
3.
Feasibility Study
The feasibility study was carried out to check if the application was possible to run considering economic,
technical and operational aspect.
The technical feasibility was for sure proven because all that owner needed was a server to handle all the orders
from clients.
The economic feasibility was proven when the cost of building the application was not much. And moreover by
doing business online it led to more of profit. Hence economically feasible.
The operational feasibility of application was proven by the need itself. The application was operational and it can
be easily implemented.Hence the application was feasible to proceed with development.
9
System Requirement Specification (SRS)
Functional Requirements:
Non-Functional Requirements:
1. Reliability
2. Interactive
3. Understandability
4. Testability
5. Good User Interface
6. Speedy
7. Good Performance
8. Efficiency
9.
10
Data and Control Flow
Diagram
11
Login
Search
View Product
Categories
And Product Details
Add to Cart
Checkout
Continue
Shopping
Enter shipping
Address
Confirm order
& Payment
Logout
12
Login
Manage
Users
Manage
Categories Track
Manage
& Customers’
Products orders & Roles
Delivery
View Reports
Orders History
Customer
Communicatio
n
Logout
13
Entities & the Relationship
Entities:
Relationships
Buy PRODUCTS
USERS
Give Are of
ORDERS
14
SYSTEM DESIGN
Modularization of Design
Our e-commerce application, which is an online shopping web site that accommodates viewing and searching
products, buying products, making orders, giving feedback, and managing the users.
These are the basic modules that make up a simple e-commerce application. However, there can be many more
interesting modules that can be added to the preceding list based on your innovation. You can add modules like
news, a feedback section, a wish-list section, and so on, to make the user more attached to the website and
encourage him/her to visit the site more often and recommend it to others. 9.
The first three modules listed previously are used by the consumer visiting the site: buying products, adding them
to the cart, creating orders, and making payments online. The last two modules listed are administrative activities
in the sense that the Manager and the executives of the site take care of the order status of different orders,
communicating with the consumers who have made orders, managing the product categories, products, and its
stock, and managing different users of the site and their roles.
Let’s have a brief look at each of these modules and their activities.
15
time, they will need to register at the site by submitting personal details, after the user registers to the site, he/she
can log in and shop for the products to buy online. 10.
This is an integral part and the core of a shopping web site. This module contains listing of products, viewing
them in a detail page, and adding them to the cart. The user has the flexibility of adding and deleting items in the
cart and can also save the items in the cart for a specific period. A cart in a shopping web site generally holds
items and their quantity, individual price, and the total price of all the items together. It is represented in a tabular
form for easy reading and manipulation. Each record in the cart table holds an item, the quantity, the price of the
item, and the total (which is the price of the item multiplied by quantity). A cart can hold any number of such
records, and the total price of all the items is calculated. This is the order amount excluding the discounts and
shipping charges. After the cart is ready, the user can check out to generate the order.
11.
This module takes care of generating orders once the cart is ready with items. An order consists of the cart
information—that is, the product name, quantity, individual price, and total price. Apart from these, it also
includes discounts, and shipping charges. All these make up the total order amount the customer has to pay. The
customer has to provide the billing and shipping address and then confirm the order. Upon confirmation, the
customer is redirected to a payment gateway site for paying the amount using a credit card.
Most web sites today implement an API provided by the credit card gateways. Upon successful transaction, the
customer is redirected back to the site. However, in our application, we will not redirect the customer to any
payment gateway site. After we make the application real, you can go to any popular payment gateway site, such
as PayPal, Verisign, and so on.
12.
16
4. User and Role Management
This module is an admin-related activity. First, roles need to be defined, and each user being created is associated
with a role. The different roles defined in our application are Administrator/ Manager, and Customer.
Administrator — the super user of the site. The Administrator has complete access to all the information in the
site, including order management and product management, has access to all the sales.
We concentrated more on the front end—that is, the shopping cart and order generation—and less on the
administration activity.
Customer — the end user. The customer is the person who shops for the products and buys them online.
This module is about managing products and orders. The Administrator / Manager take care of maintaining this
information. The operations include adding/editing/deleting/selecting categories and products, keeping track of
the stock of the products, keeping track of the orders and their status, and taking care of the delivery of orders. 13.
17
DATABASE DESIGN
18
Objective of using Database:The general theme behind a database is to handle as an integrated
whole. There is none of artificiality that is normally embedded in separate file or application. A database is a
collection of interrelated data stored with minimum redundancy to serve many users quickly and efficiently. The
general objective is to make information access easy quick inexpensive and flexible for the user.
In database design several specific objective are considered:
1. Controlled redundancy: Redundant data occupies space and therefore is wasteful. A unique
aspect of database design is string data only once, which controls redundancy and controls systems
performance.
2. Ease of learning and use: A major feature of a user-friendly database package is how easy it
is to learn and use. Related to this point is that a database can be modified without interfering with
established way of using the data.
14.
4. More information at low cost: Using, storing and modifying data at low cost is important.
Hardware price are falling & software and programming costs are on the rise. This means that
programming and software enhancements should be kept simple and easy update.
5. Accuracy and integrity: The accuracy of database ensures that data quality and content
remain constant. Integrity controls & detects data inaccuracies where they occur.
6. Recovery from failure: With multi-user access to the database the system must quickly
7. Privacy and security: For data remain private, security measures must be taken to prevent
unauthorized access. Database security means that are protected from various forms of destruction. 15.
19
Main Tables in our Database
16.
20
b) Products Table
(
17.
21
(d) OrderDetails Table
Field Name Datatype
OrderId Number
ProductId Number
Quantity Number
18.
19.
22
(h) Categories Table
Field Name Datatype
CategoryId Auto number
CategoryName Text
IsActive Yes/no
20.
23
USER INTERFACES
&
IT’S CODING
24
Index.php
25
Index.php
<?php
include("dbconfig.php");
$query = "select * from addproducts limit 9";
$result = mysql_query($query);
?>
<html>
<head>
<title>SignIn</title>
<link rel="icon" href="images/favicon.png" type="image/x-icon" />
</head>
<body>
<?php include("left.php"); ?>
<!-- end of left content -->
<div class="center_content">
<div class="center_title_bar">Latest Products</div>
<?php
while($row = mysql_fetch_assoc($result)){
$i=0;
do
{
$url = "admin/upload/default.jpg";
if(file_exists("admin/upload/".$row['id'].".jpg"))
$url = "admin/upload/".$row['id'].".jpg";
?>
<div class="prod_box">
<div class="top_prod_box"></div>
<div class="center_prod_box">
<div class="product_title"><a href="details.php"><?php echo $row['name'] ?></a></div>
<div class="product_img"><a href="details.php?id=<?php echo $row['id']?>"><img src="<?php echo
$url ?>" width="130px" height="115px" border="0" title="header=[Zoom] body=[ ]
fade=[on]"/></a></div>
<div class="prod_price"><span class="reduce"><?php echo $row['price'] ?>$</span><span
class="price"><?php echo $row['price']?>$</span></div>
</div>
<div class="bottom_prod_box"></div>
<div class="prod_details_tab"><a href="addtocart.php" title="header=[Add to cart] body=[ ]
fade=[on]"><img src="images/cart.gif" alt="" border="0" class="left_bt" /></a><a href="http://all-free-
download.com/free-website-templates/" title="header=[Specials] body=[ ] fade=[on]"><img
26
src="images/favs.gif" alt="" border="0" class="left_bt" /></a><a href="http://all-free-download.com/free-
website-templates/" title="header=[Gifts] body=[ ] fade=[on]"><img src="images/favorites.gif"
alt="" border="0" class="left_bt" /></a><a href="details.php?id=<?php echo $row['id']?>"
title="header=[details] body=[ ] fade=[on]" class="prod_details">details</a></div>
</div>
<?php
$i++;
if($i >= 3) break;
}while($row = mysql_fetch_assoc($result));
}
?>
</div></body>
</html>
<!-- end of center content -->
<!-- right content starts here -->
<?php include("right.php") ?>
<!-- end of right content -->
</div>
<!-- end of main content -->
<?php include("footer.php") ?>
27
Productlist.php
28
Productlist.php
<?php
include("dbconfig.php");
$cat = $_GET['cat'];
$result = mysql_query($query);
?>
<html>
<head>
<title>SignIn</title>
</head>
<body>
<div class="center_content">
29
<div class="center_title_bar">Latest Products</div>
<?php
while($row = mysql_fetch_assoc($result)){
$i=0;
do
$url = "admin/upload/default.jpg";
if(file_exists("admin/upload/".$row['id'].".jpg"))
$url = "admin/upload/".$row['id'].".jpg";
?>
<div class="prod_box">
<div class="top_prod_box"></div>
<div class="center_prod_box">
</div>
<div class="bottom_prod_box"></div>
30
border="0" class="left_bt" /></a><a href="details.php?id=<?php echo $row['id']?>" title="header=[details]
body=[ ] fade=[on]" class="prod_details">details</a></div>
</div>
<?php
$i++;
}while($row = mysql_fetch_assoc($result));
?>
</div></body>
</html>
</div>
32.
31
Details.php
32
Details.php
<?php include("dbconfig.php");
$id = $_GET['id'];
$result = mysql_query($query);
?>
<html>
<head>
<title>SignIn</title>
</head>
<body>
33
<div class="center_content">
<?php
$row = mysql_fetch_assoc($result);
$url = "admin/upload/default.jpg";
if(file_exists("admin/upload/".$row['id'].".jpg"))
$url = "admin/upload/".$row['id'].".jpg";
?>
<div class="prod_box_big">
<div class="top_prod_box_big"></div>
<div class="center_prod_box_big">
</div>
<div class="details_big_box">
<div class="specifications">
34
</div>
</div>
<div class="bottom_prod_box_big"></div>
</div>
<div class="prod_box_big">
<div class="top_prod_box_big"></div>
<div class="center_prod_box_big">
<strong>GENERAL FEATURES</strong>
</tr>
</tr>
35
<tr bgcolor="#dad0d0" height="25px"onmouseover="this.style.background='#7BBCC7'"
onMouseOut="this.style.background='#dad0d0'" >
<td align="left"> Architecture</td>
</tr>
</tr>
</tr>
<td align="left"> Speed</td>
</tr>
</tr>
36
<tr bgcolor="#EEE6E6" height="25px" onMouseOver="this.style.background='#7BBCC7'"
onMouseOut="this.style.background='#EEE6E6'">
</tr>
</tr>
</tr>
</table>
</div>
<div class="bottom_prod_box_big"></div>
</div>
</div>
</body></html>
</div>
38
Addtocart.php
<?php include("dbconfig.php");
if(isset($_GET['rid']))
{session_start();}
else
{
$id = $_GET['id'];
session_start();
if(isset($_SESSION['cart']))
{
$cart = $_SESSION['cart'];
$cart = $cart.",".$id;
$_SESSION['cart'] = $cart;
}
else
{
$cart = $id;
$_SESSION['cart'] = $cart;
}
}
$cart = $_SESSION['cart'];
//die($cart);
$query = "select * from addproducts where id in($cart)";
//die($query);
$result = mysql_query($query);
?>
39
<div class="center_content">
?>
<tr onMouseOver="this.style.background='#7BBCC7'"
onMouseOut="this.style.background='#EEE6E6'">
<td align="center"><img src="<?php echo $url ?>" width="66" height="75" title="header=[pendrives]
body=[ ] fade=[on]" /></td>
<td><a href="details.php?id=<?php echo $id ?>" title="header=[pendrives] body=[ ] fade=[on]"
style="text-decoration:none;"><?php echo $row['name'] ?></a></td>
<td title="header=[unit price] body=[ ] fade=[on]"><?php echo $row['price'] ?></td>
<td title="header=[quantity] body=[ ] fade=[on]">1</td>
<td><a href="removeprd.php?id=<?php echo $row['id'] ?>"><img src="images/delete.png"
height="50px" width="40px" title="header=[remove] body=[ ] fade=[on]" /></a></td>
<td title="header=[total] body=[ ] fade=[on]"><?php echo $row['price'] ?></td>
</tr>
<?php } ?>
</table>
</div>
40
</div>
</div>
<div class="bottom_prod_box_big"></div>
</div>
</form>
</div>
</div></body>
</html>
<!-- end of center content -->
<?php include("right.php") ?>
<!-- end of right content -->
</div>
<!-- end of main content -->
<?php include("footer.php") ?>
41.
41
Signin.php
42
Signin.php
<?php include("header.php") ?>
<html>
<head>
<title>SignIn</title>
</head>
<body>
<div class="center_content">
43
<div align="center">
<?php
$msg = "";
if(isset($_GET['msg']))
$msg=$_GET['msg'];
echo $msg;
?>
</div>
</script>
<div class="prod_box_big">
<div class="top_prod_box_big"></div>
<div class="center_prod_box_big">
<div class="signin_form">
<div class="form_row">
<label class="signin"><strong>Email:</strong></label>
</div>
44
<div class="form_row">
<label class="signin"><strong>Password:</strong></label>
</div>
<div class="form_row">
</div>
</div>
</div>
<div class="bottom_prod_box_big"></div>
</div>
</form>
</div>
</div>
</body>
</html>
45
<!-- end of right content -->
</div>
Checkout.php
46
Checkout.php
<?php include("dbconfig.php");
session_start();
$cart = $_SESSION['cart'];
//die($cart);
//die($query);
$result = mysql_query($query);
?>
47
<div class="crumb_navigation"> Navigation: <a href="index.php">Home</a><
<html>
<head>
<title>Checkout</title>
</head>
<body>
<div class="center_content">
<div class="prod_box_big">
<div class="top_prod_box_big"></div>
<div class="center_prod_box_big">
<div class="addtocart_form">
48
<div class="table">
<div class="tr_addtocart"></div>
<th width="10%">Total</th>
</tr>
<div class="tr_cart"></div>
<?php
$url = "admin/upload/default.jpg";
if(file_exists("admin/upload/".$row['id'].".jpg"))
49
$url = "admin/upload/".$row['id'].".jpg";
?>
<tr
onMouseOver="this.style.background='#7BBCC7'" onMouseOut="this.style.background='#EEE6E6'">
</tr>
<?php } ?>
</table>
onMouseOver="this.style.background='#7BBCC7'" onMouseOut="this.style.background='#EEE6E6'">Net
50
<div style="border-left:thin solid; border-right:thin solid; border-top:thin solid; height:30px">
<tr>
</tr>
</table>
</div>
"this.style.background='#dad0d0'">
Card
<tr>
51
<td width="71">Card Type: </td>
<td width="268"><label>
</tr>
<tr>
<td>Number:</td>
</label></td>
</tr>
52
<tr>
<td>Expires:</td>
<td><label>Select Months
<select name="select">
<option value="1">Jan</option>
<option value="2">Feb</option>
<option value="3">Mar</option>
<option value="4">April</option>
<option value="5">May</option>
<option value="6">June</option>
<option value="7">July</option>
<option value="8">Aug</option>
<option value="9">Sep</option>
<option value="10">Oct</option>
<option value="11">Nov</option>
<option value="12">Dec</option>
</select>
53
Select Years
<select name="select2">
<option value="5">2009</option>
<option value="6">2010</option>
<option value="7">2011</option>
<option value="8">2012</option>
<option value="9">2013</option>
<option value="10">2014</option>
<option value="11">2015</option>
<option value="12">2016</option>
<option value="13">2017</option>
</select>
</label></td>
</tr>
</table></td>
</tr>
54
<tr bgcolor="#EEE6E6" height="25px" onMouseOver="this.style.background='#7BBCC7'"
onMouseOut="this.style.background='#EEE6E6'" >
</td>
</tr>
"this.style.background='#dad0d0'" >
</td>
</tr>
"this.style.background='#EEE6E6'">
55
<a href="creditcard.php" style="text-decoration:none;" title="header=[cash on delivery] body=[ ]
Delivery</a>
</td>
</tr>
"this.style.background='#dad0d0'">
</td>
</tr>
"this.style.background='#EEE6E6'">
fade=[on]">Confirm Payment</a></td>
</tr>
</table>
56
</div>
</div>
</div></div></div></body></html><
</div>
</div>
</div>
<div class="bottom_prod_box_big"></div>
</div>
</div>
</form>
</div>
</div>
</div>
57
<?php include("footer.php") ?>
Cashdelievery.php
58
Cashdelievery.php
class="current">Category name</span></div>
<html>
<head>
<title>SignIn</title>
59
<link rel="icon" href="images/favicon.png" type="image/x-icon" />
</head>
<body>
<div class="center_content">
<div align="center">
<?php
$msg = "";
if(isset($_GET['msg']))
$msg=$_GET['msg'];
echo $msg;
?>
</div>
<div class="prod_box_big">
60
<div class="top_prod_box_big"></div>
<div class="center_prod_box_big">
<div class="address_form">
<div class="form_row">
onMouseOut="this.style.background='#FFFFFF'"/>
</div>
<div class="form_row">
onMouseOut="this.style.background='#FFFFFF'"/>
</div>
<label class="address"><strong>Address:</strong></label>
<label>
</label>
61
</div>
<div class="form_row">
onMouseOut="this.style.background='#FFFFFF'"/>
</div>
<div class="form_row">
onMouseOut="this.style.background='#FFFFFF'" />
</div>
<div class="form_row">
<label class="address"><strong>Email:</strong></label>
onMouseOut="this.style.background='#FFFFFF'"/>
</div>
<div class="form_row">
62
<label class="address"><strong>State:</strong></label>
<label></label>
<option>U.P</option>
<option>Delhi</option>
</select>
</div>
<div class="form_row">
<label class="address"><strong>City:</strong></label>
<label></label>
<select name="select2">
<option>Bareilly</option>
</select>
</div>
<div class="form_row">
63
<label class="address"><strong>Pincode:</strong></label>
onMouseOut="this.style.background='#FFFFFF'"/>
</div>
<div class="form_row">
<label class="address"></label>
</div>
<div class="form_row">
<label class="address"></label>
</div>
fade=[on]" class="address">Submit</a></div>
</div>
<div>
</div>
</div>
<div class="bottom_prod_box_big"></div>
</div>
64
</form>
</div>
</div></body>
</html>
</div>
65
TESTING
66
The testing strategy used by us is White Box Testing whereby we execute all the statements once to check their
resultant behavior and match the result with our expectations. However in our application we don’t have as such
statements as in a simple program so we simply traversed each link and page once to check if it is functioning
properly as desired.
The test suite or test cases are for input driven programs like console applications so we didn’t had any specific
input. However we created few accounts for setting as input to website to login. These accounts are under name
admin, Kanika, Krishna etc. with admin account at administrative level and Kanika, Krishna at user level.
45.
67
PERT CHART
68
PERT (Project Evaluation & Review Technique) Charts consists of network of boxes and arrows. The boxes
represent activities and arrow represents task dependencies. For each task there are three time estimates i.e.
minimum, optimum & maximum it can take to be completed. A critical path (shown by thick arrows) is path
having critical tasks. The PERT CHART for our project is:
Databas Database
e Code part
Design 25, 30, 35
2, 5, 7
Testing &
Plannin Debuggin
g g
& 2, 5, 10
Analysi
s User User
5, 7, 10 Interfac Interfac
e e
Design Coding Finish
10,15,20 15,20,30 0
Documentatio
n
5, 10, 15
46.
69
GANTT CHART
70
GANTT CHARTS are mainly used to allocate resources to activities. The resources allocated to activities include
staff, hardware and software. These charts are useful for resource planning. It is a special type of bar chart where
each bar represents an activity. The bars are drawn along a timeline. Each bar has white as well as shaded portion.
The shaded portion shows the time each task is estimated to take and white portion shows slack time i.e.
maximum delay possible as well as allowed for each task.
10TH OCT 20TH OCT 5TH NOV 25TH NOV 25TH DEC 8TH JAN 15TH
JAN
Planning
&
Analysis
Db Design
UI Design
UI
Coding
Db Coding
Testing &
Debugging
Documentation
47.
71
FUTURE SCOPE
&
LIMITATIONS
72
FUTURE SCOPE & ENHANCEMENTS:
In future our application can be connected to a viable gateway of online payment system for
making project actually implemental.
It could be easily used to reach those customers who don’t belong to place where the actual store
is.
By providing good services and on time delivery with good quality goods, goodwill of store can
be increased.
LIMITATION:
Our project’s main limitation is that there is no online payment system and validation of credit
cards. 48.
73
BIBLIOGRAPHY
74
The following books were referred during the analysis and execution phase of the project
Books Referred:
Websites Referred:
http://www.phptpoit.com
75
GLOSSARY
76
ATTRIBUTE:They are the characteristics of an entity.
CART:A virtual shopping basket that stores all the products taken by customer to buy.
DATABASE:A database is a collection of interrelated data stored with minimum redundancy to serve
many users quickly and efficiently.
DFD:The Data flow Diagram shows the flow of data among processes.
GANTT CHART:Chart showing allocation of resources (people, hardware & software) along the
PERT CHART:Chart showing different tasks of a project with their estimated time of completion.
PROJECT:The project is a system that gives the systematic way of planning and working.
SRS:A legal document, specifying functional and non-functional requirements of project, which is signed by
user.
TESTING:A phase in software development life cycle where results are checked against the desired result
and behavior.
WHITE-BOX TESTING:A testing strategy where the code is visible to testing team. The team
checks each line of code by traversing each page/statement once for successful execution.
77