0% found this document useful (0 votes)
54 views

Project Report PDF

Uploaded by

deepanshu sharma
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
54 views

Project Report PDF

Uploaded by

deepanshu sharma
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 65

JP INSTITUTE OF ENGINEERING & TECHNOLOGY,

MEERUT

A Project report on Online Shopping

Submitted in partial fulfillment of the requirements


for the award of the degree of

Bachelor of Technology
in
Computer Science & Engineering

Submitted by:

Md Azad Alam(Project Lead) (Univ. Roll No- 1628210045)


Emtiyaz Ansari ( Univ. Roll No- 1628210031 )
Aman Kumar ( Univ. Roll No- 1628210012 )

Under The Guidance of (Mr. Sreesh Gaur)


DR.A.P.J ABDUL KALAMTECHNICAL UNIVERSITY,
LUCKNOW, UTTAR PRADESH
Session: 2019-20

TABLE OF CONTENTS
Page

DECLARATION ................................................................................................... ii
CERTIFICATE ................................................................................................... iii
ACKNOWLEDGEMENTS .................................................................................. iv
ABSTRACT........................................................................................................... v
LIST OF TABLES.................................................................................................. vii
LIST OF FIGURES................................................................................................ viii
LIST OF SYMBOLS ............................................................................................. ix
LIST OF ABBREVIATIONS................................................................................ x
CHAPTER 1(Introduction, Background of the Problem, Statement of Problem Etc.) 1

1. INTRODUCTION
1.1 PROJECT OBJECTIVES
1.2 PROJECT OVER VIEW
1.3 PROJECT SCOPE
1.4 STUDY OF SYSTEMS
1.4.1 MODULES
1.4.1.1 ADMIN
1.4.1.2 MODERATOR
1.4.1.3 USER

2. SYSTEM ANALYSIS
2.1 EXISTING SYSTEM
2.2 PROPOSED SYSTEM
2.3 SYSTEM REQUIREMENT SPECIFICATION
2.3.2 SYSTEM OBJECTIVES
2.3.3 SYSTEM REQUIREMENTS
2.3.3.1 NON FUNCTIONAL
REQUIREMENT
2.3.3.2 FUNCTIONAL REQUIREMENT
3. SYSTEM DESIGN
3.1 INPUT AND OUTPUT DESIGN
3.1.1 INPUT DESIGN
3.1.2 OUTPUT DESIGN
3.2 DATABASE
3.3 SYSTEM TOOLS
3.3.1 FRONT END
3.3.2 BACK END

LIST OF TABLE

3.4 TABLES
3.1 LOGIN TABLE 28

3.2 USER DETAILS 28

3.3 PRODUCT DETAILS 29

3.4 PRODUCT ORDERS 29

LIST OF FIGURES

1.1 ADMIN MODULE 5


1.2 MANAGE MODERATORS 6
1.3 MANAGE PRODUCTS 8
1.4 MANAGE USERS 9
1.5 MANAGE ORDERS 10
1.5 MODERATOR MODULE 11
1.7 USER MODULE 12
E-R DIAGRAMS & DFD
3.5 LOGIN 30
3.6 USER DETAILS 30
3.7 PRODUCT DETAILS 31
3.8 PRODUCT ORDERS 31

APPENDIX B .................................................................................................... 47
REFERENCES.................................................................................................. 49
CERTIFICATE

This is to certify that this Project Report entitled “Online Shopping” which is submitted
by Md Azad Alam (Roll No.- 1628210045), in the partial fulfillment, for the award of
degree of Bachelor of Technology in Department of Computer Science & Engineering,
of JP INSTITUTE OF ENGINEERING & TECHNOLOGY, Meerut, affiliated to
DR. A.P.J. ABDUL KALAMTECHNICAL UNIVERSITY, Lucknow; is carried out
by him/her under my supervision.
The matter embodied in this Project Work has not been submitted earlier for award of
any degree or diploma in any university/institution to the best of our knowledge and
belief.

(Mr Sreesh Gaur) (Mr Prashant Verma)


Project Guide Project incharge

Date: 15/06/2020

DECLARATION
I hereby declare that this submission is our own work and that, to the best of our
knowledge and belief, it contains no material previously published or written by another
person nor material which to a substantial extent has been accepted for the award of any
other degree or diploma of the university or other institute of higher learning, except
where due acknowledgment has been made in the text.

Name: Md Azad Alam


Roll No.: 1628210045
Date: 15/02/2020

ACKNOWLEDGEMENT

It gives us a great sense of pleasure to present the report of the Project Work, undertaken
during B. Tech. Final Year. We owe special debt of gratitude to Mr Prashant Verma
Department of Computer Science & Engineering, JP Institute of Engineering &
Technology, Meerut for his constant support and guidance throughout the course of our
work. His sincerity, thoroughness and perseverance have been a constant source of
inspiration for us. It is only his cognizant efforts that our endeavors have seen light of the
day.

We also take the opportunity to acknowledge the contribution of Mr Abhinay


Agarwal, DIRECTOR,JP Institute of Engineering & Technology, Meerut for his full
support and assistance during the development of the project.

We also do not like to miss the opportunity to acknowledge the contribution of all
faculty members of the department for their kind assistance and cooperation during the
development of our project.

Last but not the least, we acknowledge our friends for their contribution in the
completion of the project.

ABSTRACT

The business to consumer aspect of electronic commerce (e-commerce) is themost visible


business use of the World Wide Web. The primary goal of an e-commercesite is to sell goods and
services online.This project deals with developing an e-commerce website for Online laptops and
phone sale. The system is implemented using a backend database, a middle tier ofMicrosoft
Internet Information Services (IIS) and a web browser as thefront end client.In order to develop
an e-commerce website, a number of Technologies must bestudied and understood. These
include multi-tiered architecture, server and client sidescripting techniques such as programming
language (such as php), relational databases (such as MySQL).In this project, the main aim is to
demonstrate that with better interaction features in laptops andsmartphones web sites could
improve sales over the net.
An online shopping system that permits a customer to submit online orders for items and/or
services from a store that serves both walk-in customers and online customers. The online
shopping system presents an online display of an order cut off time and an associated delivery
window for items selected by the customer. The system accepts the customer's submission of a
purchase order for the item in response to a time of submission being before the order cut off
time. The online shopping system does not settle with a credit supplier of the customer until the
item selected by the customer is picked from inventory but before it is delivered. Therefore, the
customer can go online and make changes to the order. In addition, available service windows
are presented to the customer as a function of customer selected order and service types and
further, the order picking is assigned in accordance with a picker's preference. When ordering
goods, many shopping systems provide a virtual shopping cart for holding items selected for
purchase. Successive items selected for purchase are placed into the virtual shopping cart until a
customer completes their shopping trip. Virtual shopping carts may be examined at any time, and
their contents can be edited or deleted at the option of the customer. Once the customer decides
to submit a purchase order, the customer may print the contents of the virtual shopping basket in
order to obtain a hard copy record of the transaction.

CHAPTER 1

INTRODUCTION
Anything that customers purchases affects environment by means of delivery, whether they have
the product shipped at home or drive to a brick and mortar store(supermarket). In earlier days
people used to go to different shops before purchasing as they didn’t have a great deal of easy
access to information on products. Due to the development of World Wide Web it has now
become easy to access the products available worldwide without wasting time, money and other
resources apart from helping environment. Centre for Energy and Climate Solutions suggests
that we can protect land and save energy by shopping online. (Trask, 2006)

The example of Ocado Group plc that delivers the grocery directly to the customer instead of
shopping from the supermarket helped in controlling the carbon emissions. Many supermarkets
such as Marks and Spencer’s, John Lewis, Amazon, Carbon Cart etc. have their own websites
are selling greener products and offering more choices to customers. Markham (1998)
Ocado’s mission is to revolutionise the way people shop by giving them innovative and greener
alternatives to traditional shopping. Using the cutting edge technology in their delivery model
helps them to cut price, deliver quality and save environment.

‘Meat free Mondays’ creates environmental awareness of climate changing impact of production
of meat and consumption. By using bio- diesel in delivery vans the emission is reduced. They
deliver their products from the state-of-the-art warehouses directly to consumer home. They are
using anaerobic digestion to produce electricity from the leftover food. The company has their
own green team called eco-warriors to increase environment awareness amongst the staff. They
have slots allotted for green van area-wise to reduce carbon emission. They use combined heat
and power (CHP) which is energy efficient process to mitigate environmental impact. A lot of
recycling works using closed loop grocery bag recycling by keeping a track of the consumption
of plastic bags and batteries.

Bricks and mortar store eat up lot of energy and resources. Online shopping retail companies
stores goods in direct warehouse which saves cost of fixtures and glitzy gimmicks of brick and
mortar store.

External Analysis of Online Shopping Industry


PESTEL Analysis
Political

The country is politically stable and the environment is suitable to promote online shopping
industry. The government is all open to offer the infrastructural and policy support needed to
make the experience of online shopping safer, efficient making it friendly to consumer, sellers
and environment which will help them meet the standards of carbon emission and reduce green
house gases set by The Kyoto Protocol and The Copenhagen Climate Council. The UK
government is taking up broadband and digital media growth rapidly paving way for online
shopping.

Economic
Online shopping has the potential to create huge opportunities for innovation and economic
growth in UK market which is facing recession. Online shopping will help in economic
efficiency increasing competitiveness and profitability by mitigating environmental impacts.

Social
Social awareness about environment is also driving people not to drive to the physical shops and
buy online with increase in internet connection. The people are more technology equipped than
before. Many retail chain such as Marks and Spencer, Ocado, etc are now promoting green
concept to sell their products online and generating goodwill which is ultimately helping them to
reduce costs and increase profits.

Technological
Technology is one of the key drivers to successfully implement effective online shopping. The
banking system and internet payments are some areas of concern but with improvements in
technologies related to internet security such as in Amazon.com shopping experiences are
becoming more convenient and safer. The countries, organisations and internet community must
concentrate on technologies by using effective payment, delivery and storage means e.g. Ocado
warehouses and deliveries, Mega electric cars, etc.

Environment
Organisation are now challenging the status quo and thinking of changing the way of doing
business because of energy prices. During the recent spike in gas prices online shopping brought
some respite to these shops which incurred significant losses otherwise. Implementing online
sales plan will assist a company to develop a baseline of energy use, actively managing energy
use and costs, reduce emissions without negative effect on operations, continue to improve
energy use and product output overtime and document savings for internal and external use eg.
Emission credits.

Legal

More environmental regulation from governments will also support energy efficient technologies
such as online shopping. Consumer Protection (Direct Selling) Act 2000 helps consumer on
issues related to online shopping.

Porter’s five forces:


Bargaining power of Suppliers: As the online shopping is a huge network with many suppliers
the bargaining power of supplier is not strong. Suppliers can be rapidly switched without
affecting disrupting consumers shopping experience.

Bargaining power of customers: The customers of Schneider Electric have an equally strong
bargaining power because of the easy of information available about other competitors. There
will not much competition if the services and solutions provided have to be customised as per the
consumer needs.

Restriction to new entry: The industry is expanding with new keeping the market open for new
entrants. An innovative idea such as CarbonCart is sufficient to become successful even with
limited resources.

Substitution effect: There are varied solutions to same problem for example electricity can be
saved by insulation as well as improvement in technology. This keeps many substitution
companies open to competition for Schneider Electric.

Existing competition: There are many competitors as mentioned above which can become
potential threat in future. Schneider Electric has been successful in acquiring many companies to
reduce competition and increase their market.

Key Players:
Online Sellers
Argos is allowing customers to order goods through mobile phone by jumping in text messaging
bandwagon.(BBC, 2002). Dell has been pioneer in direct selling proving that complex product
such as computer can be sold without contact. Ocado Group plc (Ocado) is engaged in online
retailing and distribution of groceries and consumer goods in UK. Ocado offers delivery of
grocery products to customers centrally picked from a single highly-automated warehouse. John
Lewis knew from talking to their customers just how important energy saving has become to
their customers, and they developed their own range of electrical appliances with that in mind.
Aixam Mega sells light and private commercial vehicles with their key priority for environment.
Their investment in product market and designs has made them leader in market of affordable
diesel and electric vehicle.

Opportunities for Schneider Electric:


“You must be the change you wish to see in the world” Mahatma Gandhi. Schneider Electric’s
mission is to assist organisation and people make most of their energy. Their vision is to extract
more while consuming lesser resources from our earth.

The company can involve itself in supplying parts to vehicles such as those Designed by Aixam
Mega, Ocado etc to help them become more energy efficient. This will help them to expand its
business on the vehicle segments as well. Schneider can also start its online selling business on
the lines of Amazon, Waitrose, Dell etc. using the direct selling model. This will help to
eliminate distributors thereby reducing costs and increasing profitability. The company can use
Bricks and clicks model where consumer can order online and pick goods from shop or get it
delivered at home. The company can appoint various people as marketing agents to popularise
and sell their products and earn commission. Schneider can use the text and take home service
used by Argos to sell their products through mobile phone.

Threat to Schneider
CarbonCart.com allows one to pick “Green” products and create a positive impact by
neutralizing more than hundred percent of the carbon emission generated from delivery. This
makes consumer feel responsible about the contribution they make to environment by purchasing
from CarbonCart.com. The direct selling model of Schneider will not be successful if people will
buy more from such industries.

Online shopping model for company such as Schneider which sells technical products will have
to backed up by large number of customer assistant agents which requires huge financial and
human resources where the attrition rate is high.

Segmentation
The company can segment online market based on
Direct customers: These are the customers who have purchase product directly from the
company. The direct customers will get maximum price advantage in product and services.
Distributors: Customers who have purchased product through distributor network operators
(DNO’s) of company’s product. The distributors will be given fixed targets and will be allowed
to sell the product in their name and below the price. This helps company to increase sales and
avoid dealing with individual consumers. Through the company DNO’s can reduce maintenance
and installation cost with superior network design.

Direct Agents: The agents are the customers who have sold company products to their
customers. These agents will sell products at higher prices and will be given incentives on sales.

1.1 PROJECT OBJECTIVE:

The objective of the project is to make an application in android platform to purchase items
in an existing shop. In order to build such an application complete web support need to be
provided. A complete and efficient web application which can provide the online shopping
experience is the basic objective of the project. The web application can be implemented in the
form of an android application with web view.

1.2 PROJECT OVER VIEW:

The central concept of the application is to allow the customer to shop virtually using the
Internet and allow customers to buy the items and articles of their desire from the store. The
information pertaining to the products are stores on an RDBMS at the server side (store).

The Server process the customers and the items are shipped to the address submitted by them.
The application was designed into two modules first is for the customers who wish to buy the
articles. Second is for the storekeepers who maintains and updates the information pertaining to
the articles and those of the customers. The end user of this product is a departmental store where
the application is hosted on the web and the administrator maintains the database. The
application which is deployed at the customer database, the details of the items are brought
forward from the database for the customer view based on the selection through the menu and
the database of all the products are updated at the end of each transaction. Data entry into the
application can be done through various screens designed for various levels of users. Once the
authorized personnel feed the relevant data into the system, several reports could be generated as
per the security.

1.3 PROJECT SCOPE:

This system can be implemented to any shop in the locality or to multinational branded
shops having retail outlet chains. The system recommends a facility to accept the orders 24*7
and a home delivery system which can make customers happy.

If shops are providing an online portal where their customers can enjoy easy shopping
from anywhere, the shops won’t be losing any more customers to the trending online shops such
as flipcart or ebay. Since the application is available in the Smartphone it is easily accessible and
always available.

1.4 STUDY OF THE SYSTEM

1.4.1 MODULES:

The system after careful analysis has been identified to be presented with

the following modules and roles.

The modules involved are:

Administrator

Moderators

Users
1.4.1.1 ADMINISTRATOR:
The administrator is the super user of this application. Only admin have access into this
admin page. Admin may be the owner of the shop. The administrator has all the information
about all the users and about all products.

This module is divided into different sub-modules.

1. Manage Moderators

2. Manage Products

3. Manage Users

4. Manage Orders

MANAGE MODERATOR
Fig 1.2: Manage Moderator

Add Moderator

Only admin is having the privilege to add a moderator. A moderator can be considered as a staff
who manages the orders or owner of a group of products

Admin can restrict a moderator from managing the orders by blocking them. Admin can unblock
a blocked user if needed.

Remove Moderator

Admin has privilege to delete a moderator who was added.


Search moderator:

All existing moderators can be viewed by the administrator as a list. If there is number of
moderators and admin need to find one of them, the admin can search for a moderator by name.

MANAGE PRODUCTS

Fig 1.3: Manage Products

Add Products
The shopping cart project contains different kind of products. The products can be classified into
different categories by name. Admin can add new products into the existing system with all its
details including an image.

Delete Products

Administrator can delete the products based on the stock of that particular product.

Search products

Admin will have a list view of all the existing products. He can also search for a particular
product by name.

MANAGE USER

Fig 1.4: Manage User

View Users
The admin will have a list view of all the users registered in the system.

Admin can view all the details of each user in the list except password.

Add Users

Admin has privileges to add a user directly by providing the details.

Delete &Block Users

Administrator has a right to delete or block a user. The default status of a new user registered is
set as blocked. The admin must accept the new user by unblocking him.

MANAGE ORDERS

View Order

Administrator can view the Orders which is generated by the users. He can verify the details of
the purchase.

Delete order

Admin can delete order from the orders list when the product is taken for delivery.

1.4.1.2 MODERATORS
Fig 1.6: Moderator Module
A moderator is considered as a staff who can manage orders for the time being. As a future
update moderator may give facility to add and manage his own products . Moderators can reduce
the work load of admin. Now moderator has all the privilege an admin having except managing
other moderators. He can add products and users. He can also check the orders and edit his
profile.

Manage products

Manage users

Manage orders

1.4.1.3 USERS
A new user will have to register in the system by providing essential details in order to view the
products in the system. The admin must accept a new user by unblocking him.

Login

A user must login with his user name and password to the system after registration.
View Products

User can view the list of products based on their names after successful login. A detailed
description of a particular product with product name, products details, product image, price can
be viewed by users.

Search Product

Users can search for a particular product in the list by name.

Add to cart:

The user can add the desired product into his cart by clicking add to cart option on the product.

He can view his cart by clicking on the cart button. All products added by cart can be viewed in
the cart. User can remove an item from the cart by clicking remove.

Submit Cart:

After confirming the items in the cart the user can submit the cart by providing a delivery
address.On successful submitting the cart will become empty.

History

In the history the user will have a view of pending orders.

Edit Profile

The user can view and edit the profile.


CHAPTER 1

SYSTEM ANALYSIS
System analysis is the process of gathering and interpreting facts, diagnosing problems and using
the information to recommend improvements on the system. System analysis is a problem
solving activity that requires intensive communication between the system users and system
developers.

System analysis or study is an important phase of any system development process. The system
is viewed as a whole, the inputs are identified and the system is subjected to close study to
identify the problem areas. The solutions are given as a proposal. The proposal is reviewed on
user request and suitable changes are made. This loop ends as soon as the user is satisfied with
the proposal.

2.1 EXISTING SYSTEM


The current system for shopping is to visit the shop manually and from the available product
choose the item customer want and buying the item by payment of the price of the item .

1. It is less user-friendly.
2. User must go to shop and select products.

3. It is difficult to identify the required product.

4. Description of the product limited.

5. It is a time consuming process

6. Not in reach of distant users.

2.2 PROPOSED SYSTEM

In the proposed system customer need not go to the shop for buying the products. He can
order the product he wish to buy through the application in his Smartphone. The shop owner will
be admin of the system. Shop owner can appoint moderators who will help owner in managing
the customers and product orders. The system also recommends a home delivery system for the
purchased products.

2.3 SYSTEM REQUIREMENT SPECIFICATION

2.3.1 GENERAL DESCRIPTION

Product Description:

The system consists of two parts .A web application which can provide the online shopping
service and an android application for the customer to

access the web service from his Smartphone. Web application should be able to help the
customer for selecting his item and to help the owner in managing the orders from the customers.

Problem Statement:

As online shopping became a trend nowadays the regular shops are losing their customers to
online brands. Customers have effortless shopping experience and saving time through shopping
online. For competing with those online brands , If shops are providing an online portal where
their customers can shop through internet and get the products at their doors it will increase the
number of customers.
2.3.2 SYSTEM OBJECTIVES

To provide an android application for online shopping of products in an existing shop.


To provide a online shopping web site for the same shop.

2.3.3 SYSTEM REQUIREMENTS


2.3.3.1 NON FUNCTIONAL REQUIREMENTS

i. EFFICIENCY REQUIREMENT

When an online shopping cart android application implemented customer can purchase product
in an efficient manner.

ii. RELIABILITY REQUIREMENT

The system should provide a reliable environment to both customers and owner. All orders
should be reaching at the admin without any errors.

iii. USABILITY REQUIREMENT

The android application is designed for user friendly environment and ease of use.

iv. IMPLEMENTATION REQUIREMENT


Implementation of the system using css and html in front end with jsp as back end and it will be
used for database connectivity. And the database part is developed by mysql. Responsive web
designing is used for making the website compatible for any type of screen.

v. DELIVERY REQUIREMENT

The whole system is expected to be delivered in four months of time with


a weekly evaluation by the project guide.

2.3.3.2 FUNCTIONAL REQUIREMENTS

USER

USER LOGIN Description of


feature

This feature used by the user to login into system. A user must login with his user name and
password to the system after registration. If they are invalid, the user not allowed to enter the
system.

Functional requirement
- Username and password will be provided after user registration is confirmed.

- Password should be hidden from others while typing it in the field


REGISTER NEW USER Description of
feature

A new user will have to register in the system by providing essential details in order to view the
products in the system. The admin must accept a new user by unblocking him.

Functional requirement

- System must be able to verify and validate information.

- The system must encrypt the password of the customer to provide

security.

PURCHASING AN ITEM Description of


feature

The user can add the desired product into his cart by clicking add to cart option on the product.
He can view his cart by clicking on the cart button. All products added by cart can be viewed in
the cart. User can remove an item from the cart by clicking remove. After confirming the items
in the cart the user can submit the cart by providing a delivery address. On successful submitting
the cart will become empty.

Functional requirement

- System must ensure that, only a registered customer can purchase items.
ADMIN

MANAGE USER Description of


feature

The administrator can add user, delete user, view user and block user.

MANAGE MODERATOR

Description of feature

The administrator can add moderator, delete moderator, block moderator and search for a
moderator.

MANAGE PRODUCTS Description of


feature

The administrator can add product, delete product and view product.

MANAGE ORDERS

Description of feature

The administrator can view orders and delete orders.

Functional requirements
-Admin account should be secured so that only owner of the shop can access that account

MODERATOR

Description of features

A moderator is considered as a staff who can manage orders for the time being. As a future
update moderator may give facility to add and manage his own products. Moderators can reduce
the work load of admin. Now moderator has all the privilege of an admin having except
managing other moderators. He can manage users and manage products. He can also check the
orders and edit his profile.

Functional requirement

-The system must identify the login of a moderator.

CHAPTER 1

SYSTEM DESIGN
System design is the solution for the creation of a new system. This phase focuses on the
detailed implementation of the feasible system. It emphasis on translating design. Specifications
to performance specification. System design has two phases of development

Logical design

Physical design
During logical design phase the analyst describes inputs (sources), output s(destinations),
databases (data sores) and procedures (data flows) all in a format that meets the user
requirements. The analyst also specifies the needs of the user at a level that virtually determines
the information flow in and out of the system and the data resources. Here the logical design is
done through data flow diagrams and database design. The physical design is followed by
physical design or coding. Physical design produces the working system by defining the design
specifications, which specify exactly what the candidate system must do. The programmers write
the necessary programs that accept input from the user, performnecessary processing on accepted
data and produce the required report on a hard copy or display it on the screen.

3.1 INPUT AND OUTPUT DESIGN

3.1.1 INPUT DESIGN:

Input design is the link that ties the information system into the world of its

users. The input design involves determining the inputs, validating the data, minimizing the data
entry and provides a multi-user facility. Inaccurate inputs are the most common cause of errors in
data processing. Errors entered by the data entry operators can be controlled by input design. The
user-originated inputs are converted to a computer based format in the input design. Input data
are collected and organized into groups of similar data. Once identified, the appropriate input
media are selected for processing. All the input data are validated and if any data violates any
conditions, the user is warned by a message. If the data satisfies all the conditions, it is
transferred to the appropriate tables in the database. In this project the student details are to be
entered at the time of registration. A page is designed for this purpose which is user friendly and
easy to use. The design is done such that users get appropriate messages when exceptions occur.

3.3 SYSTEM TOOLS


The various system tools that have been used in developing both the front end and the back end
of the project are being discussed in this chapter.

3.3.1.FRONT END:

JSP, HTML, CSS, JAVA SCRIPT,ANDROID are utilized to implement the frontend.

Java Server Pages (JSP)

Different pages in the applications are designed using jsp. A Java Server Pages component is a
type of Java servlet that is designed to fulfil the role of a user interface for a Java web
application. Web developers write JSPs as text files that combine HTML or XHTML code, XML
elements, and embedded JSP actions and commands. Using JSP, one can collect input from users
through web page.

HTML (Hyper Text Markup Language)

HTML is a syntax used to format a text document on the web.

CSS (Cascading Style Sheets)

CSS is a style sheet language used for describing the look and formatting of a document written
in a markup language.

Java Script

JS is a dynamic computer programming language. It is most commonly used as part of web


browsers, whose implementations allow client-side
scripts to interact with the user, control the browser, communicate asynchronously, and alter the
document content that is displayed.

Java Script is used to create pop up windows displaying different alerts in the system like “User
registered successfully”, ”Product added to cart” etc.

Android

The application is delivered to customer through an android application.

So android platform is used to develop the user application.

3.3.2 BACK END

The back end is implemented using MySQL which is used to design the databases.

MySQL
MySQL is the world's second most widely used open-source relational database management
system (RDBMS). The SQL phrase stands for Structured Query Language.

An application software called Navicat was used to design the tables in MySQL.

3.4 TABLES

LOGIN
Fig 3.1: Login Table

PRODUCT DETAILS

Fig 3.3: Product Details Table

PRODUCT ORDERS
Fig 3.4: Product Orders table
3.5 E-R DIAGRAMS

LOGIN

Fig 3.5: Login

PRODUCT DETAILS

Fig 3.7: Product Details

COMPLETE DIAGRAM
Fig 3.9: Complete Diagram
3.6 DATA FLOW DIAGRAM

A Data Flow Diagram (DFD) is a structured analysis and design tool that can be used for
flowcharting. A DFD is a network that describes the flow of data and the processes that change
or transform the data throughout a system. This network is constructed by using a set of symbols
that do not imply any physical implementation. It has the purpose of clarifying system
requirements and identifying major transformations. So it is the starting point of the design phase
that functionally decomposes the requirements specifications down to the lowest level of detail.
DFD can be considered to an abstraction of the logic of an information-oriented or a process-
oriented system flow-chart. For these reasons DFD’s are often referred to as logical data flow
diagrams.

EXTERNAL ENTITY

An external entity is a source or destination of a data flow. Only those entities which originate or
receive data are represented on a data flow diagram. The symbol used is a rectangular box.
PROCESS

A process shows a transformation or manipulation of data flow within the system. The
symbol used is an oval shape.

DATAFLOW
The data flow shows the flow of information from a source to its destination. Data flow is
represented by a line, with arrowheads showing the direction of flow. Information always flows
to or from a process and may be written, verbal or electronic. Each data flow may be referenced
by the processes or data stores at its head and tail, or by a description of its contents.

DATA STORE

A data store is a holding place for information within the system: It is represented by an
open ended narrow rectangle. Data stores may be long-term files such as sales ledgers, or may be
short-term accumulations: for example batches of documents that are waiting to be processed.
Each data store should be given a reference followed by an arbitrary number.

Codes:

Index.jsp

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Home</title>
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"
integrity="sha384-
BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u"
crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>

<c:set var="x" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:set var="x" value="${x+1 }"></c:set>
</c:forEach>

<header>
<h1>
Tiazon
</h1>
<nav>
<ul>
<li><a href="Controller?page=index">Home</a></li>
<c:choose>
<c:when test="${session == null}">
<li><a
href="Controller?page=login">Login</a></li>
<li><a href="Controller?page=sign-up">Sign-
up</a></li>
</c:when>
<c:when test="${session != null}">
<li><a href="Controller?page=logout"
style="color: #F24638;">Logout</a></li>
<li><a href="#">My Account(<c:out
value="${username }"></c:out>)</a></li>
</c:when>
</c:choose>
<li><a href="Controller?page=showcart">cart(<c:out
value="${x}"/>)</a></li>
</ul>
</nav>
</header>

<div class="tiazon-content">
<div class="container">
<div class="row">
<div class="col-md-4"><!-- left -->
<div class="list-group"><!-- products -->
<a href="Controller?page=all-products"
class="list-group-item" style="background: #d6d4d3;">
All Products
</a>
<a href="Controller?page=mobiles" class="list-
group-item">Mobiles</a>
<a href="Controller?page=laptops" class="list-
group-item">Laptops</a>
<a href="Controller?page=clothing" class="list-
group-item">Clothing</a>
<a href="Controller?page=home-decor"
class="list-group-item">Home Decor</a>
</div>
</div><!-- left -->

<div class="col-md-8"><!-- right -->


<h2 style="text-align: center;">Featured
Products</h2><br>

<h5>Sort by(Price):</h5>
<form action="Controller" method="get" style="border:
none;margin:0px;padding: 0px;margin-bottom: 20px;">
<input type="hidden" name="page" value="price-sort">
<input type="hidden" name="action" value="index">
<select name="sort">
<option value="low-to-high">Low to high</option>
<option value="high-to-high">high to low</option>
</select>
<input type="submit" value="Go!">
</form>

<c:forEach items="${list }" var="product">

<c:if test="${product.getFeatured() == 'yes' }">

<div class="col-md-4">
<img src="${product.getImage() }"
class="img-responsive" ><br>
<div class="text-center"><a
style="color: black;"><c:out value="${product.getName() }"></c:out></a></div>
<p style="text-align: center;">
&#x20b9; <c:out value="${ product.getPrice() }"></c:out></p>
<div class="text-center"> <a
class="btn btn-primary" href="Controller?page=addtocart&action=index&id=<c:out
value="${product.getId()}"/>">Add to Cart</a> </div><br>
</div>

</c:if>

</c:forEach>

</div>
</div>
</div>
</div>

<footer>
<div class="footer"> &copy; 2018 Copyright:
<a href="Controller?page=index"> Tiazon.com</a>
</div>
</footer>

</body>
</html>

Admin:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Home</title>
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"
integrity="sha384-
BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u"
crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>

<c:set var="x" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:set var="x" value="${x+1 }"></c:set>
</c:forEach>

<header>
<h1>
Tiazon
</h1>
<nav>
<ul>
<li><a href="Controller?page=index">Home</a></li>
<c:choose>
<c:when test="${session == null}">
<li><a
href="Controller?page=login">Login</a></li>
<li><a href="Controller?page=sign-up">Sign-
up</a></li>
</c:when>
<c:when test="${session != null}">
<li><a href="Controller?page=logout"
style="color: #F24638;">Logout</a></li>
<li><a href="#">My Account(<c:out
value="${username }"></c:out>)</a></li>
</c:when>
</c:choose>
<li><a href="Controller?page=showcart">cart(<c:out
value="${x}"/>)</a></li>
</ul>
</nav>
</header>

<div class="tiazon-content">
<div class="container">
<div class="row">
<div class="col-md-4"><!-- left -->
<div class="list-group"><!-- products -->
<a href="Controller?page=all-products"
class="list-group-item" style="background: #d6d4d3;">
All Products
</a>
<a href="Controller?page=mobiles" class="list-
group-item">Mobiles</a>
<a href="Controller?page=laptops" class="list-
group-item">Laptops</a>
<a href="Controller?page=clothing" class="list-
group-item">Clothing</a>
<a href="Controller?page=home-decor"
class="list-group-item">Home Decor</a>
</div>
</div><!-- left -->

<div class="col-md-8"><!-- right -->


<h2 style="text-align: center;">Featured
Products</h2><br>

<h5>Sort by(Price):</h5>
<form action="Controller" method="get" style="border:
none;margin:0px;padding: 0px;margin-bottom: 20px;">
<input type="hidden" name="page" value="price-sort">
<input type="hidden" name="action" value="index">
<select name="sort">
<option value="low-to-high">Low to high</option>
<option value="high-to-high">high to low</option>
</select>
<input type="submit" value="Go!">
</form>

<c:forEach items="${list }" var="product">

<c:if test="${product.getFeatured() == 'yes' }">

<div class="col-md-4">
<img src="${product.getImage() }"
class="img-responsive" ><br>
<div class="text-center"><a
style="color: black;"><c:out value="${product.getName() }"></c:out></a></div>
<p style="text-align: center;">
&#x20b9; <c:out value="${ product.getPrice() }"></c:out></p>
<div class="text-center"> <a
class="btn btn-primary" href="Controller?page=addtocart&action=index&id=<c:out
value="${product.getId()}"/>">Add to Cart</a> </div><br>
</div>

</c:if>

</c:forEach>

</div>
</div>
</div>
</div>
<footer>
<div class="footer"> &copy; 2018 Copyright:
<a href="Controller?page=index"> Tiazon.com</a>
</div>
</footer>

</body>
</html>

All products:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Home</title>
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"
integrity="sha384-
BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u"
crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>

<c:set var="x" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:set var="x" value="${x+1 }"></c:set>
</c:forEach>

<header>
<h1>
Tiazon
</h1>
<nav>
<ul>
<li><a href="Controller?page=index">Home</a></li>
<c:choose>
<c:when test="${session == null}">
<li><a
href="Controller?page=login">Login</a></li>
<li><a href="Controller?page=sign-up">Sign-
up</a></li>
</c:when>
<c:when test="${session != null}">
<li><a href="Controller?page=logout"
style="color: #F24638;">Logout</a></li>
<li><a href="#">My Account(<c:out
value="${username }"></c:out>)</a></li>
</c:when>
</c:choose>
<li><a href="Controller?page=showcart">cart(<c:out
value="${x}"/>)</a></li>
</ul>
</nav>
</header>

<div class="tiazon-content">
<div class="container">
<div class="row">
<div class="col-md-4"><!-- left -->
<div class="list-group"><!-- products -->
<a href="Controller?page=all-products"
class="list-group-item" style="background: #d6d4d3;">
All Products
</a>
<a href="Controller?page=mobiles" class="list-
group-item">Mobiles</a>
<a href="Controller?page=laptops" class="list-
group-item">Laptops</a>
<a href="Controller?page=clothing" class="list-
group-item">Clothing</a>
<a href="Controller?page=home-decor"
class="list-group-item">Home Decor</a>
</div>
</div><!-- left -->

<div class="col-md-8"><!-- right -->


<h2 style="text-align: center;">All Products</h2><br>

<h5>Sort by(Price):</h5>
<form action="Controller" method="get" style="border:
none;margin:0px;padding: 0px;margin-bottom: 20px;">
<input type="hidden" name="page" value="price-sort">
<input type="hidden" name="action" value="all-
products">
<select name="sort">
<option value="low-to-high">Low to high</option>
<option value="high-to-high">high to low</option>
</select>
<input type="submit" value="Go!">
</form>

<c:forEach items="${list }" var="product">

<div class="col-md-4">
<img src="${product.getImage() }"
class="img-responsive" ><br>
<div class="text-center"><a
style="color: black;"><c:out value="${product.getName() }"></c:out></a></div>
<p style="text-align: center;">
&#x20b9; <c:out value="${ product.getPrice() }"></c:out></p>
<div class="text-center"> <a
class="btn btn-primary" href="Controller?page=addtocart&action=allproducts&id=<c:out
value="${product.getId()}"/>">Add to Cart</a> </div><br>
</div>

</c:forEach>

</div>
</div>
</div>
</div>

<footer>
<div class="footer"> &copy; 2018 Copyright:
<a href="Controller?page=index"> Tiazon.com</a>
</div>
</footer>

</body>
</html>

Cart:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Home</title>
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"
integrity="sha384-
BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u"
crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>

<c:set var="x" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:set var="x" value="${x+1 }"></c:set>
</c:forEach>

<header>
<h1>
Tiazon
</h1>
<nav>
<ul>
<li><a href="Controller?page=index">Home</a></li>
<c:choose>
<c:when test="${session == null}">
<li><a
href="Controller?page=login">Login</a></li>
<li><a href="Controller?page=sign-up">Sign-
up</a></li>
</c:when>
<c:when test="${session != null}">
<li><a href="Controller?page=logout"
style="color: #F24638;">Logout</a></li>
<li><a href="#">My Account(<c:out
value="${username }"></c:out>)</a></li>
</c:when>
</c:choose>
<li><a href="Controller?page=showcart">cart(<c:out
value="${x}"/>)</a></li>
</ul>
</nav>
</header>

<div class="container">

<c:choose>
<c:when test="${x == 1}">
<h4 style="margin-top: 40px;">My shopping
bag(<c:out value="${x}"/> item)</h4>
</c:when>
<c:when test="${x > 1}">
<h4 style="margin-top: 40px;">My shopping
bag(<c:out value="${x}"/> items)</h4>
</c:when>
<c:otherwise >
<h4 style="margin-top: 40px;">Your Shopping Bag is
Empty</h4>
</c:otherwise>

</c:choose>
<table>
<tr>
<th>Item Name</th>
<th>Price</th>
<th>Category</th>
<th>Remove Item</th>
</tr>
</table>

<c:set var="total" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:forEach items="${list }" var="Product">
<c:if test="${i == Product.getId() }">

<c:set var="total" value="${total + Product.getPrice() }"></c:set>

<table style="table-layout: fixed;width: 100%;">


<tr>
<td style="width: 100px;"><img
src="${Product.getImage()}" height="100" width="150" > (<c:out
value="${Product.getName()}"/>)</td>
<td style="width: 50px;"><c:out
value="${Product.getPrice()}"/></td>
<td style="width: 100px;"><c:out
value="${Product.getCategory()}"/></td>
<td style="width: 100px;"><a
href="Controller?page=remove&id=<c:out value="${Product.getId()}"/>"><span class="btn
btn-danger">X</span></a></td>
</tr>
</table>
</c:if>
</c:forEach>
</c:forEach>
<h4 style="margin-top: 40px;margin-bottom: 40px;">Order Total: &#x20b9; (<c:out
value="${ total}"></c:out>)</h4>

<a href="Controller?page=success"><input type="submit" value="Proceed to


Checkout" class="btn btn-success" style="width:100%;padding:8px;font-size:16px;"></a><br>
<a href="Controller?page=index"><input type="button" value="Continue Shopping"
class="btn btn-warning" style="width:100%;padding:8px;font-size:16px;"></a>

</div>

<footer style="margin-top: 40px;">


<div class="footer"> &copy; 2018 Copyright:
<a href="Controller?page=index"> Tiazon.com</a>
</div>
</footer>

</body>
</html>

Clothing:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Home</title>
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"
integrity="sha384-
BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u"
crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>

<c:set var="x" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:set var="x" value="${x+1 }"></c:set>
</c:forEach>

<header>
<h1>
Tiazon
</h1>
<nav>
<ul>
<li><a href="Controller?page=index">Home</a></li>
<c:choose>
<c:when test="${session == null}">
<li><a
href="Controller?page=login">Login</a></li>
<li><a href="Controller?page=sign-up">Sign-
up</a></li>
</c:when>
<c:when test="${session != null}">
<li><a href="Controller?page=logout"
style="color: #F24638;">Logout</a></li>
<li><a href="#">My Account(<c:out
value="${username }"></c:out>)</a></li>
</c:when>
</c:choose>
<li><a href="Controller?page=showcart">cart(<c:out
value="${x}"/>)</a></li>
</ul>
</nav>
</header>

<div class="tiazon-content">
<div class="container">
<div class="row">
<div class="col-md-4"><!-- left -->
<div class="list-group"><!-- products -->
<a href="Controller?page=all-products"
class="list-group-item" style="background: #d6d4d3;">
All Products
</a>
<a href="Controller?page=mobiles" class="list-
group-item">Mobiles</a>
<a href="Controller?page=laptops" class="list-
group-item">Laptops</a>
<a href="Controller?page=clothing" class="list-
group-item">Clothing</a>
<a href="Controller?page=home-decor"
class="list-group-item">Home Decor</a>
</div>
</div><!-- left -->

<div class="col-md-8"><!-- right -->


<h2 style="text-align: center;">Clothing</h2><br>

<h5>Sort by(Price):</h5>
<form action="Controller" method="get" style="border:
none;margin:0px;padding: 0px;margin-bottom: 20px;">
<input type="hidden" name="page" value="price-sort">
<input type="hidden" name="action" value="clothing">
<select name="sort">
<option value="low-to-high">Low to high</option>
<option value="high-to-high">high to low</option>
</select>
<input type="submit" value="Go!">
</form>

<c:forEach items="${list }" var="product">

<c:if test="${product.getCategory() == 'clothing'


}">

<div class="col-md-4">
<img src="${product.getImage() }"
class="img-responsive" ><br>
<div class="text-center"><a
style="color: black;"><c:out value="${product.getName() }"></c:out></a></div>
<p style="text-align: center;">
&#x20b9; <c:out value="${ product.getPrice() }"></c:out></p>
<div class="text-center"> <a
class="btn btn-primary" href="Controller?page=addtocart&action=clothing&id=<c:out
value="${product.getId()}"/>">Add to Cart</a> </div><br>
</div>

</c:if>

</c:forEach>

</div>
</div>
</div>
</div>
<footer>
<div class="footer"> &copy; 2018 Copyright:
<a href="Controller?page=index"> Tiazon.com</a>
</div>
</footer>

</body>
</html>

Login:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Login page</title>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>

<c:set var="x" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:set var="x" value="${x+1 }"></c:set>
</c:forEach>

<header>
<h1>
Tiazon
</h1>
<nav>
<ul>
<li><a href="Controller?page=index">Home</a></li>
<c:choose>
<c:when test="${session == null}">
<li><a
href="Controller?page=login">Login</a></li>
<li><a href="Controller?page=sign-up">Sign-
up</a></li>
</c:when>
<c:when test="${session != null}">
<li><a href="Controller?page=logout"
style="color: #F24638;">Logout</a></li>
<li><a href="#">My Account</a></li>
</c:when>
</c:choose>
<li><a href="Controller?page=showcart">cart(<c:out
value="${x}"/>)</a></li>
</ul>
</nav>
</header>

<div class="signup-header">
<h2>Login to <mark>Tiazon</mark></h2>
</div>

<form method="post" action="Controller">

<input type="hidden" name="page" value="login-form">

<!-- Validations errors -->


<font color="#F24638"><c:out value="${msg }"></c:out></font>

<div class="signup-group">
<label>Username</label>
<input type="text" name="username" placeholder="Your Username"
value="<c:out value="${username }"></c:out>">
</div>
<div class="signup-group">
<label>Password</label>
<input type="password" name="password" placeholder="Enter
password">
</div>
<div class="signup-group">
<button type="submit" name="login" class="signup-btn">Log
in</button>
</div>
<p>
New to Tiazon? <a href="Controller?page=sign-up"
style="color:#F24638;">Create Account</a>
</p>
</form>
<br><br><br>
<footer style="position: fixed;bottom: 0;left: 0;width: 100%;">
<div class="footer"> &copy; 2018 Copyright:
<a href="Controller?page=index"> Tiazon.com</a>
</div>
</footer>

</body>
</html>

Sign-up:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Sign up page</title>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>

<c:set var="x" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:set var="x" value="${x+1 }"></c:set>
</c:forEach>

<header>
<h1>
Tiazon
</h1>
<nav>
<ul>
<li><a href="Controller?page=index">Home</a></li>
<c:choose>
<c:when test="${session == null}">
<li><a
href="Controller?page=login">Login</a></li>
<li><a href="Controller?page=sign-up">Sign-
up</a></li>
</c:when>
<c:when test="${session != null}">
<li><a href="Controller?page=logout"
style="color: #F24638;">Logout</a></li>
<li><a href="#">My Account</a></li>
</c:when>
</c:choose>
<li><a href="Controller?page=showcart">cart(<c:out
value="${x}"/>)</a></li>
</ul>
</nav>
</header>

<div class="signup-header">
<h2>Signup with Tiazon</h2>
</div>

<form method="post" action="Controller">

<input type="hidden" name="page" value="sign-up-form">

<!-- Validations errors -->


<font color="#F24638"><c:out value="${msg }"></c:out></font>

<div class="signup-group">
<label>Name</label>
<input type="text" name="name" placeholder="Name goes here"
value="<c:out value="${name }"></c:out>" required>
</div>
<div class="signup-group">
<label>Email</label>
<input type="email" name="email" placeholder="Your email address"
value="<c:out value="${email }"></c:out>" required>
</div>
<div class="signup-group">
<label>Username</label>
<input type="text" name="username" placeholder="Username"
value="<c:out value="${username }"></c:out>" required>
</div>

<div class="signup-group">
<label>Address</label>
<input type="text" name="address" placeholder="your address goes here"
value="<c:out value="${address }"></c:out>" required>
</div>
<div class="signup-group">
<label>Password</label>
<input type="password" name="password_1" placeholder="Enter
password" required>
</div>
<div class="signup-group">
<label>Confirm Passowrd</label>
<input type="password" name="password_2" placeholder="Re-enter
password" required>
</div>
<div class="signup-group">
<button type="submit" name="register" class="signup-
btn">Register</button>
</div>
<p>
Already have an account? <a href="Controller?page=login"
style="color:#F24638;">Login!</a>
</p>
</form>
<br><br><br>
<footer>
<div class="footer"> &copy; 2018 Copyright:
<a href="Controller?page=index"> Tiazon.com</a>
</div>
</footer>

</body>
</html>

Clothing:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Home</title>
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"
integrity="sha384-
BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u"
crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>

<c:set var="x" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:set var="x" value="${x+1 }"></c:set>
</c:forEach>

<header>
<h1>
Tiazon
</h1>
<nav>
<ul>
<li><a href="Controller?page=index">Home</a></li>
<c:choose>
<c:when test="${session == null}">
<li><a
href="Controller?page=login">Login</a></li>
<li><a href="Controller?page=sign-up">Sign-
up</a></li>
</c:when>
<c:when test="${session != null}">
<li><a href="Controller?page=logout"
style="color: #F24638;">Logout</a></li>
<li><a href="#">My Account(<c:out
value="${username }"></c:out>)</a></li>
</c:when>
</c:choose>
<li><a href="Controller?page=showcart">cart(<c:out
value="${x}"/>)</a></li>
</ul>
</nav>
</header>

<div class="tiazon-content">
<div class="container">
<div class="row">
<div class="col-md-4"><!-- left -->
<div class="list-group"><!-- products -->
<a href="Controller?page=all-products"
class="list-group-item" style="background: #d6d4d3;">
All Products
</a>
<a href="Controller?page=mobiles" class="list-
group-item">Mobiles</a>
<a href="Controller?page=laptops" class="list-
group-item">Laptops</a>
<a href="Controller?page=clothing" class="list-
group-item">Clothing</a>
<a href="Controller?page=home-decor"
class="list-group-item">Home Decor</a>
</div>
</div><!-- left -->

<div class="col-md-8"><!-- right -->


<h2 style="text-align: center;">Clothing</h2><br>
<h5>Sort by(Price):</h5>
<form action="Controller" method="get" style="border:
none;margin:0px;padding: 0px;margin-bottom: 20px;">
<input type="hidden" name="page" value="price-sort">
<input type="hidden" name="action" value="clothing">
<select name="sort">
<option value="low-to-high">Low to high</option>
<option value="high-to-high">high to low</option>
</select>
<input type="submit" value="Go!">
</form>

<c:forEach items="${list }" var="product">

<c:if test="${product.getCategory() == 'clothing'


}">

<div class="col-md-4">
<img src="${product.getImage() }"
class="img-responsive" ><br>
<div class="text-center"><a
style="color: black;"><c:out value="${product.getName() }"></c:out></a></div>
<p style="text-align: center;">
&#x20b9; <c:out value="${ product.getPrice() }"></c:out></p>
<div class="text-center"> <a
class="btn btn-primary" href="Controller?page=addtocart&action=clothing&id=<c:out
value="${product.getId()}"/>">Add to Cart</a> </div><br>
</div>

</c:if>

</c:forEach>

</div>
</div>
</div>
</div>

<footer>
<div class="footer"> &copy; 2018 Copyright:
<a href="Controller?page=index"> Tiazon.com</a>
</div>
</footer>
</body>
</html>

Home-décor:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Home</title>
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"
integrity="sha384-
BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u"
crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>

<c:set var="x" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:set var="x" value="${x+1 }"></c:set>
</c:forEach>

<header>
<h1>
Tiazon
</h1>
<nav>
<ul>
<li><a href="Controller?page=index">Home</a></li>
<c:choose>
<c:when test="${session == null}">
<li><a
href="Controller?page=login">Login</a></li>
<li><a href="Controller?page=sign-up">Sign-
up</a></li>
</c:when>
<c:when test="${session != null}">
<li><a href="Controller?page=logout"
style="color: #F24638;">Logout</a></li>
<li><a href="#">My Account(<c:out
value="${username }"></c:out>)</a></li>
</c:when>
</c:choose>
<li><a href="Controller?page=showcart">cart(<c:out
value="${x}"/>)</a></li>
</ul>
</nav>
</header>

<div class="tiazon-content">
<div class="container">
<div class="row">
<div class="col-md-4"><!-- left -->
<div class="list-group"><!-- products -->
<a href="Controller?page=all-products"
class="list-group-item" style="background: #d6d4d3;">
All Products
</a>
<a href="Controller?page=mobiles" class="list-
group-item">Mobiles</a>
<a href="Controller?page=laptops" class="list-
group-item">Laptops</a>
<a href="Controller?page=clothing" class="list-
group-item">Clothing</a>
<a href="Controller?page=home-decor"
class="list-group-item">Home Decor</a>
</div>
</div><!-- left -->

<div class="col-md-8"><!-- right -->


<h2 style="text-align: center;">Home Decor</h2><br>

<h5>Sort by(Price):</h5>
<form action="Controller" method="get" style="border:
none;margin:0px;padding: 0px;margin-bottom: 20px;">
<input type="hidden" name="page" value="price-sort">
<input type="hidden" name="action" value="home-
decor">
<select name="sort">
<option value="low-to-high">Low to high</option>
<option value="high-to-high">high to low</option>
</select>
<input type="submit" value="Go!">
</form>
<c:forEach items="${list }" var="product">

<c:if test="${product.getCategory() == 'home


decor' }">

<div class="col-md-4">
<img src="${product.getImage() }"
class="img-responsive" ><br>
<div class="text-center"><a
style="color: black;"><c:out value="${product.getName() }"></c:out></a></div>
<p style="text-align: center;">
&#x20b9; <c:out value="${ product.getPrice() }"></c:out></p>
<div class="text-center"> <a
class="btn btn-primary" href="Controller?page=addtocart&action=home-decor&id=<c:out
value="${product.getId()}"/>">Add to Cart</a> </div><br>
</div>

</c:if>

</c:forEach>

</div>
</div>
</div>
</div>

<footer>
<div class="footer"> &copy; 2018 Copyright:
<a href="Controller?page=index"> Tiazon.com</a>
</div>
</footer>

</body>
</html>

Laptops:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Home</title>
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"
integrity="sha384-
BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u"
crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>

<c:set var="x" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:set var="x" value="${x+1 }"></c:set>
</c:forEach>

<header>
<h1>
Tiazon
</h1>
<nav>
<ul>
<li><a href="Controller?page=index">Home</a></li>
<c:choose>
<c:when test="${session == null}">
<li><a
href="Controller?page=login">Login</a></li>
<li><a href="Controller?page=sign-up">Sign-
up</a></li>
</c:when>
<c:when test="${session != null}">
<li><a href="Controller?page=logout"
style="color: #F24638;">Logout</a></li>
<li><a href="#">My Account(<c:out
value="${username }"></c:out>)</a></li>
</c:when>
</c:choose>
<li><a href="Controller?page=showcart">cart(<c:out
value="${x}"/>)</a></li>
</ul>
</nav>
</header>

<div class="tiazon-content">
<div class="container">
<div class="row">
<div class="col-md-4"><!-- left -->
<div class="list-group"><!-- products -->
<a href="Controller?page=all-products"
class="list-group-item" style="background: #d6d4d3;">
All Products
</a>
<a href="Controller?page=mobiles" class="list-
group-item">Mobiles</a>
<a href="Controller?page=laptops" class="list-
group-item">Laptops</a>
<a href="Controller?page=clothing" class="list-
group-item">Clothing</a>
<a href="Controller?page=home-decor"
class="list-group-item">Home Decor</a>
</div>
</div><!-- left -->

<div class="col-md-8"><!-- right -->


<h2 style="text-align: center;">Laptops</h2><br>

<h5>Sort by(Price):</h5>
<form action="Controller" method="get" style="border:
none;margin:0px;padding: 0px;margin-bottom: 20px;">
<input type="hidden" name="page" value="price-sort">
<input type="hidden" name="action" value="laptops">
<select name="sort">
<option value="low-to-high">Low to high</option>
<option value="high-to-high">high to low</option>
</select>
<input type="submit" value="Go!">
</form>

<c:forEach items="${list }" var="product">

<c:if test="${product.getCategory() == 'laptops' }">

<div class="col-md-4">
<img src="${product.getImage() }"
class="img-responsive" ><br>
<div class="text-center"><a
style="color: black;"><c:out value="${product.getName() }"></c:out></a></div>
<p style="text-align: center;">
&#x20b9; <c:out value="${ product.getPrice() }"></c:out></p>
<div class="text-center"> <a
class="btn btn-primary" href="Controller?page=addtocart&action=laptops&id=<c:out
value="${product.getId()}"/>">Add to Cart</a> </div><br>
</div>

</c:if>

</c:forEach>

</div>
</div>
</div>
</div>

<footer>
<div class="footer"> &copy; 2018 Copyright:
<a href="Controller?page=index"> Tiazon.com</a>
</div>
</footer>

</body>
</html>

Mobiles:

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"


pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Home</title>
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"
integrity="sha384-
BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u"
crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>

<c:set var="x" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:set var="x" value="${x+1 }"></c:set>
</c:forEach>

<header>
<h1>
Tiazon
</h1>
<nav>
<ul>
<li><a href="Controller?page=index">Home</a></li>
<c:choose>
<c:when test="${session == null}">
<li><a
href="Controller?page=login">Login</a></li>
<li><a href="Controller?page=sign-up">Sign-
up</a></li>
</c:when>
<c:when test="${session != null}">
<li><a href="Controller?page=logout"
style="color: #F24638;">Logout</a></li>
<li><a href="#">My Account(<c:out
value="${username }"></c:out>)</a></li>
</c:when>
</c:choose>
<li><a href="Controller?page=showcart">cart(<c:out
value="${x}"/>)</a></li>
</ul>
</nav>
</header>

<div class="tiazon-content">
<div class="container">
<div class="row">
<div class="col-md-4"><!-- left -->
<div class="list-group"><!-- products -->
<a href="Controller?page=all-products"
class="list-group-item" style="background: #d6d4d3;">
All Products
</a>
<a href="Controller?page=mobiles" class="list-
group-item">Mobiles</a>
<a href="Controller?page=laptops" class="list-
group-item">Laptops</a>
<a href="Controller?page=clothing" class="list-
group-item">Clothing</a>
<a href="Controller?page=home-decor"
class="list-group-item">Home Decor</a>
</div>
</div><!-- left -->
<div class="col-md-8"><!-- right -->
<h2 style="text-align: center;">Mobiles</h2><br>

<h5>Sort by(Price):</h5>
<form action="Controller" method="get" style="border:
none;margin:0px;padding: 0px;margin-bottom: 20px;">
<input type="hidden" name="page" value="price-sort">
<input type="hidden" name="action" value="mobiles">
<select name="sort">
<option value="low-to-high">Low to high</option>
<option value="high-to-high">high to low</option>
</select>
<input type="submit" value="Go!">
</form>

<c:forEach items="${list }" var="product">

<c:if test="${product.getCategory() == 'mobiles'


}">

<div class="col-md-4">
<img src="${product.getImage() }"
class="img-responsive" ><br>
<div class="text-center"><a
style="color: black;"><c:out value="${product.getName() }"></c:out></a></div>
<p style="text-align: center;">
&#x20b9; <c:out value="${ product.getPrice() }"></c:out></p>
<div class="text-center"> <a
class="btn btn-primary" href="Controller?page=addtocart&action=mobiles&id=<c:out
value="${product.getId()}"/>">Add to Cart</a> </div><br>
</div>

</c:if>

</c:forEach>

</div>
</div>
</div>
</div>

<footer>
<div class="footer"> &copy; 2018 Copyright:
<a href="Controller?page=index"> Tiazon.com</a>
</div>
</footer>

</body>
</html>

Success:

<%@page import="com.beans.Product"%>
<%@page import="java.util.ArrayList"%>
<%@page import="javax.swing.JOptionPane"%>
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Home</title>
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"
integrity="sha384-
BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u"
crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>

<c:set var="x" value="0"></c:set>


<c:forEach items="${cartlist }" var="i">
<c:set var="x" value="${x+1 }"></c:set>
</c:forEach>

<header>
<h1>
Tiazon
</h1>
<nav>
<ul>
<li><a href="Controller?page=index">Home</a></li>
<c:choose>
<c:when test="${session == null}">
<li><a
href="Controller?page=login">Login</a></li>
<li><a href="Controller?page=sign-up">Sign-
up</a></li>
</c:when>
<c:when test="${session != null}">
<li><a href="Controller?page=logout"
style="color: #F24638;">Logout</a></li>
<li><a href="#">My Account(<c:out
value="${username }"></c:out>)</a></li>
</c:when>
</c:choose>
<li><a href="Controller?page=showcart">cart(<c:out
value="${x}"/>)</a></li>
</ul>
</nav>
</header>

<c:choose>
<c:when test="${session == null}">
<%
JOptionPane.showMessageDialog(null, "Please Login first",
"Info", JOptionPane.INFORMATION_MESSAGE);
request.getRequestDispatcher("login.jsp").forward(request,
response);
%>
</c:when>

<c:when test="${x == 0}">

<%
JOptionPane.showMessageDialog(null, "Your shopping bag is
empty", "Info", JOptionPane.INFORMATION_MESSAGE);
request.getRequestDispatcher("cart.jsp").forward(request,
response);
%>
</c:when>

<c:when test="${session != null}">

<div class="container" style="margin-top: 60px;margin-bottom:


60px;">
<h4>Thank you <font color="#6bb1f8"><c:out
value="${name }"></c:out></font> for Shopping with us. We received your order and it will be
delivered to <font color="#6bb1f8"><c:out value="${address }"></c:out></font> with in 4-5
working days.</h4>
<h4>Confirmation mail will be sent shortly to <font
color="#6bb1f8"><c:out value="${email }"></c:out></font>.</h4>
<br><br>
<a href="Controller?page=index"><input type="button"
value="Continue Shopping" class="btn btn-warning" style="width:100%;padding:8px;font-
size:16px;"></a>
</div>

</c:when>

</c:choose>

<footer style="position: fixed;bottom: 0;left: 0;width: 100%;">


<div class="footer"> &copy; 2018 Copyright:
<a href="Controller?page=index"> Tiazon.com</a>
</div>
</footer>
</body>
</html>

You might also like