Professional Documents
Culture Documents
By
CHARU JAIN
CSE/08/413
June-July 2011
Page 2 of 123
By
CHARU JAIN
CSE/08/413
June-July 2011
CERTIFICATE
This is to certify that the Project titled KIOSK MANAGEMENT SYSTEM and
submitted by CHARU JAIN having Roll No CSE/08/413 for the partial fulfillment of
the requirements for the degree of Bachelor of Technology/Engineering (B.Tech/
B.E.), embodies the bonafide work done by her under my supervision.
__________________________
Signature of the Supervisor
Place: SONEPAT
Date: 29-7-2011
Page 4 of 123
Acknowledgement
This report gives the details of the project work done in Summer
training for partial fulfillment of the requirements for the degree of
Bachelor
of
Technology/Engineering
(B.Tech/
B.E.),
under
the
____________________
Signature of the Student
Name: CHARU JAIN
Date: 29-7-2011
Page 5 of 123
Table of Contents
1 Introduction.....................................................................................................................10
1.1 Purpose....................................................................................................................10
1.2 Scope.......................................................................................................................10
2 Feasibility Report............................................................................................................11
1.1 Purpose....................................................................................................................14
Five common factors (TELOS)....................................................................................14
1.2 Scope.......................................................................................................................15
1.3 System Overview...................................................................................................15
1.4 Project References..................................................................................................16
1.5 Acronyms and Abbreviations.................................................................................16
1.6 Points of Contact.....................................................................................................17
1.6.1 Information......................................................................................................17
1.6.2 Coordination....................................................................................................17
2.1 Environment............................................................................................................17
2.1.1 Organizations Involved....................................................................................17
2.1.2 Input/ Output....................................................................................................18
2.1.3 Processing........................................................................................................18
2.1.4 Security............................................................................................................18
2.1.5 System Interaction...........................................................................................18
2.2 Current Functional Procedures...............................................................................19
2.3 Functional Objectives.............................................................................................19
2.4 Performance Objectives..........................................................................................19
2.5 Assumptions and Constraints..................................................................................19
2.6 Methodology...........................................................................................................20
2.8 Recommendation....................................................................................................20
3.1 Description of Proposed System.............................................................................20
3.2 Improvements.........................................................................................................21
3.3 Time and Resource Costs........................................................................................21
3.4 Impacts....................................................................................................................21
Page 6 of 123
8.2 Definition................................................................................................................47
8.3 Responsibilities.......................................................................................................47
8.4 Constraints..............................................................................................................48
8.5 Composition............................................................................................................48
ER Diagram..................................................................................................................50
8.6 Database Design......................................................................................................51
8.7 Table schemas........................................................................................................52
8.8 Class Diagrams and Classes....................................................................................55
8.10 Resources..............................................................................................................59
8.11 Processing.............................................................................................................59
8.12 Detailed Subsystem Design..................................................................................59
9. Source Code Details......................................................................................................59
10. Output.......................................................................................................................126
12. Bibliography.............................................................................................................130
5 Conclusion..................................................................................................................132
6 Checklist......................................................................................................................132
119
Page 9 of 123
1 Introduction
1.1 Purpose
Kiosk Management System is the online service that can be used in Reservation Centers
which allows users to reserve various facilities. Here we can take Roadways, Railways,
Airlines and Hotel Reservation as our application. The Administrator has options to
control the KMS functionalities and the users.
Users may be of three types: - Administrator, Authorized User and Visitor.
Administrator provides Login ID and Password to the user.
Authorized User will have access to all the services provided by KMS.
Visitors are unauthorized users who can just view the details that are provided by
Administrator.
1.2 Scope
The feasibility report gives us a brief about the project how project is made. Its economic,
commercial, operational all things are include The basic information provided by the
project are:
It will provide the different login option for each user of the project that include the
related information according to his privileges and display the features on just clicking
the option
1.3 Objectives
The system fulfills following objectives: 1. This application has basically three types of users as: Administrator, Visitor and
Authorized User.
2. In this application, user has a common access to book his reservation to Roadways,
Railways, Airlines and Hotel.
3. User should have a valid login id to make reservations.
4. A visitor can search for particular reservation even though he is not registered.
5. No user can have direct interaction with the database.
6. Administrator has to Log-in before to do any transaction.
7. The properties of transaction should be maintained at each and every transaction.
Kiosks are a huge opportunity for online reservation. It is an interactive computerized
unit in a reservation that combines software and hardware to provide internet,
information, transaction facilities and many customer-activated services.
Page 10 of 123
2 Feasibility Report
TABLE OF CONTENTS
1 Introduction.....................................................................................................................10
1.1 Purpose....................................................................................................................10
1.2 Scope.......................................................................................................................10
2 Feasibility Report............................................................................................................11
1.1 Purpose....................................................................................................................14
Five common factors (TELOS)....................................................................................15
1.2 Scope.......................................................................................................................15
1.3 System Overview...................................................................................................15
1.4 Project References..................................................................................................16
1.5 Acronyms and Abbreviations.................................................................................16
1.6 Points of Contact.....................................................................................................17
1.6.1 Information......................................................................................................17
1.6.2 Coordination....................................................................................................17
2.1 Environment............................................................................................................17
2.1.1 Organizations Involved....................................................................................17
2.1.2 Input/ Output....................................................................................................18
2.1.3 Processing........................................................................................................18
2.1.4 Security............................................................................................................18
2.1.5 System Interaction...........................................................................................19
2.2 Current Functional Procedures...............................................................................19
2.3 Functional Objectives.............................................................................................19
2.4 Performance Objectives..........................................................................................19
2.5 Assumptions and Constraints..................................................................................20
2.6 Methodology...........................................................................................................20
2.8 Recommendation....................................................................................................20
3.1 Description of Proposed System.............................................................................21
3.2 Improvements.........................................................................................................21
3.3 Time and Resource Costs........................................................................................21
3.4 Impacts....................................................................................................................22
Page 11 of 123
8.2 Definition................................................................................................................47
8.3 Responsibilities.......................................................................................................47
8.4 Constraints..............................................................................................................48
8.5 Composition............................................................................................................48
ER Diagram..................................................................................................................50
8.6 Database Design......................................................................................................51
8.7 Table schemas........................................................................................................52
8.8 Class Diagrams and Classes....................................................................................55
8.10 Resources..............................................................................................................59
8.11 Processing.............................................................................................................59
8.12 Detailed Subsystem Design..................................................................................59
9. Source Code Details......................................................................................................59
10. Output.......................................................................................................................126
12. Bibliography.............................................................................................................130
5 Conclusion..................................................................................................................132
6 Checklist......................................................................................................................132
17
Page 14 of 123
1.2 Scope
The feasibility report gives us a brief about the project how project is made. Its economic,
commercial, operational all things are include The basic information provided by the
project are:
It will provide the different login option for each user of the project that include the
related information according to his privileges and display the features on just clicking
the option.
Kiosks are a huge opportunity for online reservation. It is an interactive computerized
unit in a reservation that combines software and hardware to provide internet,
information, transaction facilities and many customer-activated services.
1.3
System Overview
The system fulfills following objectives: 1. This application has basically three types of users as: Administrator, Visitor and
Authorized User.
2. In this application, user has a common access to book his reservation to Roadways,
Railways, Airlines and Hotel.
3.
4.
5.
6.
Page 16 of 123
1.6
Points of Contact
1.6.1 Information
Name
SBIT
Mr. Mahendra
Charu
Chetna
Shikha
Sumit Kumar
Status
Sponsor
Trainer
Developer
Developer
Developer
Developer
Organization
Contact
SBIT
info.sbit@gmail.com
SBIT
mkshrivas@gmail.com
SBIT
cse08413.sbit@gmail.com
SBIT
chetnasaxena91@yahoo.com
SBIT
shikhamalik90@gmail.com
SBIT
sumit_kumar332@yahoo.com
1.6.2 Coordination
Various organizations that are involved for the project are:
HCL: Help us to provide the database for our project and also assist in database
development and its security implementation.
SBIT Management: Provided us the platform for the successful development of the
project
Under the guidance of our trainer Mr. Mahendra we tried to build up the project with
coordination.
The project is divided into several modules and each module is worked upon by each
member of the group. The specific schedule was provided by our project instructor based
on which our project explored.
Environment
Developer
Developer
SBIT
SBIT
cse08413.sbit@gmail.com
chetnasaxena91@yahoo.com
Shikha
Sumit Kumar
Developer
Developer
SBIT
SBIT
shikhamalik90@gmail.com
sumit_kumar332@yahoo.com
2.1.3 Processing
Operating System: Windows XP Professional, Windows 2000, Windows 7
Browser: PCs: Microsoft Windows Internet Explorer and Mozillas Firefox browser
Software: NetBeans running on Java platform
Database: Oracle 10g
Web Server: Apache Tomcat
Hardware Requirements:Server Side:
Operating System: Windows 9x/XP, Windows Server 2007.
Processor: Pentium 3.0 GHz or higher
RAM: 256 MB or more
Hard Drive: 10 GB or more
Client side:
Operating System: Windows 9x or above
Web Browser(i.e. Internet Explorer, Mozilla Firefox . etc)
Processor: Pentium III or 2.0 GHz or higher.
RAM: 256 MB or more
2.1.4 Security
For ensuring the safety of the project, a login window is provided with the following
fields:
Username
Password
It forces the access of authenticated user only to the application. An additional feature is
also provided which stores the time of users login and logout. Session are used for
security.
Page 18 of 123
2.2
The current functional procedure used by the organizations for maintaining their
hardware equipments involves the following elements:
Generally MS Excel is used by the most of the organizations which is not so user
friendly and chaotic in use for the novice user.
Retrieval and updating of the database is also a cumbersome process.
More time is consumed in case of handling the large database and sometimes it
becomes impossible to handle the data of a relatively large organization.
Sometimes it became completely unmanageable which ultimately lead to the
increase in assets of maintaining an unorganized way.
2.3
Functional Objectives
2.4
Performance Objectives
Project Tasks are directly proportional to the Performance Criteria which have been set
for the project. The Performance Criteria, therefore, determines the amount of work to be
done. So, to increase the performance criteria it is almost always necessary to increase
the Work or to obtain resources with greater capabilities (i.e. they can perform the same
work in a shorter period of time).Therefore, the performance objectives are classified as
follows:
Increase in the performance
Increase in the productivity
Fast and Easy retrieval of the data
Better security measurements
Better accuracy
2.5
The operator of the application should have the knowledge of the current system.
ADMIN will have all the permissions.
Page 19 of 123
2.6
Methodology
The survey will be done with visitors. All the perspectives of visitors about the current
system of their working will be taken. All the needs of the customer will be collected and
tried to be fulfilled. The current system of working is implemented with some advanced
features. Also survey is done with the college personals to know about what they want in
this application from their side. The quality of the software is maintained and the featured
provided by it will be helpful.
2.7
Evaluation Criteria
Ease of system use
It is easy to use, since it uses the GUI provided in the user dialog.
User friendly screens are provided.
Development time
To reduce the Resource Days by increasing the Resource Capability will not
necessarily reduce the Total Cost because the reduction in resource days may
be out weighed by the increased Resource Cost.
However, improved Resource Capability will reduce the task time and there is often a
delivery Time Cost associated with a project so that the cost to the organization will be
less or its income improved. This is the so called 'window of opportunity' factor.
2.8
Recommendation
It is strictly recommended to backup your database time to time. There are some risks
which could be tolerated in this application
If some user apply from the registration through sign up form and he will fill up wrong
details. In this case the ADMIN verify the data by the contact person and then forward
it.
3.2
Improvements
This system will improve to existing system and meet the following objectives Decrease the burden on organization
Make the services available to customers
Help the organization to manage their services
Utilize the resources in a time and cost effective way
Make the application distributed
To minimize dependency and reduce redundancy and bugs
Ensure security in terms of authentication and access of information
3.3
This system is a very flexible. The functionality can be extending according to the need
of clients.It contains several functionalities that can run in parallel during its
development. Early stages of development need some more no of employees to
understand the requirements. After database design burden on the development team will
decrease. After design phase it requires moderate number of developers to work. Under
normal circumstances, the project will take about 4 to 5 months to complete even after
some of the employees may not be available during the middle time. Initial development
cost will be more as it includes the database design and all other design activities as more
employees will be required to implement this. As project will go on its development
members will decrease and automatically the cost will reduce also.
3.4
Impacts
Page 21 of 123
3.5
This system provides best features and functionality as compare to other alternatives.
Some of the alternatives were good from security point of view but do not provide a fast
functionality as expected. Similarly other alternatives lack security and some special
features.
In all the proposed software is the best alternative for the implementation of the current
requirements. It provides best functionality by providing the following
easiness of use by users
maintaining of data in the database
High performance in terms of data retrieval, access and modification.
Ensuring security and maintainability
Interaction with the new and old users.
Page 23 of 123
Traditional excel based system :- This type of information can also be managed by
using some traditional computer systems like excel based system where user maintains all
the information in his/her computer in excel sheets instead of database. All the records
are maintained by employees itself and modified when required. But it will not be
accessible from a remote place and also information may corrupt easily and can become
redundant. Therefore this alternative is not suitable for the implementation of this project.
An alternative system can also de developed using any simple programming language
like c++, vb etc. But this type of system will not maintain security and platform
independency and performance. SO this type of system can not fulfill all the requirements
of a safe web based application. It is provided by our system using java technology and
java servlets which ensures security and maintains platform independency.
Page 24 of 123
3 Requirement Specification
Table of Contents
1 Introduction.....................................................................................................................10
1.1 Purpose....................................................................................................................10
1.2 Scope.......................................................................................................................10
2 Feasibility Report............................................................................................................11
1.1 Purpose....................................................................................................................14
Five common factors (TELOS)....................................................................................14
1.2 Scope.......................................................................................................................15
1.3 System Overview...................................................................................................15
1.4 Project References..................................................................................................16
1.5 Acronyms and Abbreviations.................................................................................16
1.6 Points of Contact.....................................................................................................17
1.6.1 Information......................................................................................................17
1.6.2 Coordination....................................................................................................17
2.1 Environment............................................................................................................17
2.1.1 Organizations Involved....................................................................................17
2.1.2 Input/ Output....................................................................................................18
2.1.3 Processing........................................................................................................18
2.1.4 Security............................................................................................................18
2.1.5 System Interaction...........................................................................................18
2.2 Current Functional Procedures...............................................................................19
2.3 Functional Objectives.............................................................................................19
2.4 Performance Objectives..........................................................................................19
2.5 Assumptions and Constraints..................................................................................19
2.6 Methodology...........................................................................................................20
2.8 Recommendation....................................................................................................20
3.1 Description of Proposed System.............................................................................20
3.2 Improvements.........................................................................................................21
3.3 Time and Resource Costs........................................................................................21
3.4 Impacts....................................................................................................................21
Page 25 of 123
Page 26 of 123
8.1 Classification...........................................................................................................47
8.2 Definition................................................................................................................47
8.3 Responsibilities.......................................................................................................47
8.4 Constraints..............................................................................................................48
8.5 Composition............................................................................................................48
ER Diagram..................................................................................................................50
8.6 Database Design......................................................................................................51
8.7 Table schemas........................................................................................................52
8.8 Class Diagrams and Classes....................................................................................55
8.10 Resources..............................................................................................................59
8.11 Processing.............................................................................................................59
8.12 Detailed Subsystem Design..................................................................................59
9. Source Code Details......................................................................................................59
10. Output.......................................................................................................................126
12. Bibliography.............................................................................................................130
5 Conclusion..................................................................................................................132
6 Checklist......................................................................................................................132
1. Introduction
1.1 Purpose
The purpose of our project is to provide the online service that can be used in Reservation
Centers which allows users to reserve various facilities. Here we can take Roadways,
Railways, Airlines and Hotel Reservation as our application online reservation.
Page 28 of 123
1.5 References:
Book References
Web References
www.google.co.in
www.wikipedia.org
2. Overall Description:
2.1 Product Perspective
As the name implies, kiosk management main function is to act as an agent, that is to
say,it provides Ticket Booking facility, Book hotel rooms for the user of this website.
But there is a restriction for the user of this site is that the user use all the facility of this
site when you have a registered user of this site.
Page 29 of 123
Page 30 of 123
The system used to run the application must support the latest version of
JavaBeans.
No data loss in case of handling of the system by the administrators or the system
related personnel.
3. System Features
ENJOY LIFE is a website through which people can book tickets, Book Hotel rooms/
buses/trains/flights according to their comfort and needs without going to its source
booking office.
Home Page:
In home page of Enjoy life a menu is available. In this menu 8 different tabs are
available.
They are :
o Home
o Trains
o Buses
o Flights
Page 31 of 123
o Hotel
o About Us
o Register
o Contact Us
Page 32 of 123
For ensuring the safety of the project, a login window is provided with the
following fields:
Username
Password
6. Other Requirements
Scalability: System should be able to handle a number of users.
For e.g. Handling around thousand users at the same time.
Usability: Simple user interfaces that a layman can understand.
Speed: Speed of the system should be responsive i.e. response to a particular action
should be available in short period of time. For e.g. on registering as a new user the
notification about the approval is sent immediately to the respective user through email.
Updating the account takes few seconds for the changes if the entry is not starred.
Appendix A: Glossary
Administrator- That provides Login ID and Password to the user.
Authorized User- will have access to all the services provided by KMS.
Visitors- are unauthorized users who can just view the details that are provided by
Administrator.
Database- In which data is stored
DFD- Data Flow Diagram
Interface- through which client send request
Server- that serves request
Page 33 of 123
Page 34 of 123
4 Design Specification
Table of Contents
1 Introduction.....................................................................................................................10
1.1 Purpose....................................................................................................................10
1.2 Scope.......................................................................................................................10
2 Feasibility Report............................................................................................................11
1.1 Purpose....................................................................................................................14
Five common factors (TELOS)....................................................................................14
1.2 Scope.......................................................................................................................15
1.3 System Overview...................................................................................................15
1.4 Project References..................................................................................................16
1.5 Acronyms and Abbreviations.................................................................................16
1.6 Points of Contact.....................................................................................................17
1.6.1 Information......................................................................................................17
1.6.2 Coordination....................................................................................................17
2.1 Environment............................................................................................................17
2.1.1 Organizations Involved....................................................................................17
2.1.2 Input/ Output....................................................................................................18
2.1.3 Processing........................................................................................................18
2.1.4 Security............................................................................................................18
2.1.5 System Interaction...........................................................................................18
2.2 Current Functional Procedures...............................................................................19
2.3 Functional Objectives.............................................................................................19
2.4 Performance Objectives..........................................................................................19
2.5 Assumptions and Constraints..................................................................................19
2.6 Methodology...........................................................................................................20
2.8 Recommendation....................................................................................................20
3.1 Description of Proposed System.............................................................................20
3.2 Improvements.........................................................................................................21
3.3 Time and Resource Costs........................................................................................21
3.4 Impacts....................................................................................................................21
3.4.1 Equipment Impacts..........................................................................................22
Page 35 of 123
Page 36 of 123
8.2 Definition................................................................................................................47
8.3 Responsibilities.......................................................................................................47
8.4 Constraints..............................................................................................................48
8.5 Composition............................................................................................................48
ER Diagram..................................................................................................................50
8.6 Database Design......................................................................................................51
8.7 Table schemas........................................................................................................52
8.8 Class Diagrams and Classes....................................................................................55
8.10 Resources..............................................................................................................59
8.11 Processing.............................................................................................................59
8.12 Detailed Subsystem Design..................................................................................59
9. Source Code Details......................................................................................................59
10. Output.......................................................................................................................126
12. Bibliography.............................................................................................................130
5 Conclusion..................................................................................................................132
6 Checklist......................................................................................................................132
Page 38 of 123
1. Revision History
Version
Name
Date
1.0
Kiosk
management
system
Initial Revision
29-7-2011
2. Approved By
Approvals should be obtained from faculty/ HOD
Name
Department
Date
Mr.Abhishek
Shukla
CSE
29-7-2011
Mr. Sanjay
CSE
29-7-2011
Page 39 of 123
Signature
3. Introduction
A software development process, also known as a software development life cycle
(SDLC), is a structure imposed on the development of a software product. Similar
terms include software life cycle and software process. It is often considered a subset
of systems development life cycle. There are several models for such processes, each
describing approaches to a variety of tasks or activities that take place during the
process.
The following sections and subsections are designed to give a detailed knowledge of
the kiosk management system which we have designed during the training section as
a small project. Different phases we covered in this project are :
Creation of Various Pages regarding Services provided by Administrator as
Railways, Roadways, Airlines and Hotel Reservation
Creation of Users (Administrator, Visitor, Authorized User)
Creation of Databases Relevant to the Application
Design of Dynamic Search Engine of the application to search for the relevant
services on the basis of inputs provided by User.
General Constraints
Development Methods
Architectural Strategies
System Architecture
Policies and Tactics
Detailed System Design
Glossary
Bibliography
3.2.1 Introduction
Purpose
This section should provide a high-level overview of how the functionality and
responsibilities of the system were partitioned and then assigned to subsystems or
components. The main purpose here is to gain a general understanding of how and why
the system was decomposed, and how the individual parts work together to provide the
desired functionality.
The purpose of our project is to provide the online service that can be used in Reservation
Centers which allows users to reserve various facilities. Here we can take Roadways,
Railways, Airlines and Hotel Reservation as our application online reservation.
Document Conventions
The format of this SRS is simple. Bold face and indentation is used on general topics and
or specific points of interest. The remainder of the document will be written using the
standard font, New Times Roman.
Only following points are taken into consideration:
Headings are written in Times New Roman with 14 font size in BOLD.
And the details are written in Times New Roman with 11 font size.
This document is intended to be read by the developer team, project managers HCL
group members, user SBIT. This is a technical document and the terms should be
understood by the customer.
The Remaining part of the SRS contains the following description:
Overall description of the project
System feature
Internal interface requirement
Other non functional requirement.
Project Scope
The software development team designs, implements, tests, and delivers these
Requirements to you. A Requirement is an atomic unit of a software product from the
viewpoint of the user. As a rule, Requirements are always correct, unambiguous,
verifiable, and traceable.
Kiosks are a huge opportunity for online reservation. It is an interactive computerized
unit in a reservation that combines software and hardware to provide internet,
information, transaction facilities and many customer-activated services. Computer
kiosks can store data locally, or they can retrieve data from a remote server over a
network. Kiosks can be used to provide information, which is great when it comes to egovernance, or for facilitating online transactions, or collecting cash in exchange for
commodities.
Page 41 of 123
This application has basically three types of users as: Administrator, Visitor and
Authorized User.
In this application, user has a common access to book his reservation to
Roadways, Railways, Airlines and Hotel.
User should have a valid login id to make reservations.
User doesnt have to make different accounts to book their Reservations.
A visitor can search for particular reservation even though he is not registered.
Administrator has the right to show availability or non-availability of bus, flight
and hotels. (not for the trains as it relates to Indian Railways)
User can check their booked status anytime.
User can also cancel their reservation, if not interested.
Booked reservations will be automatically updated in the database.
No user can have direct interaction with the database.
Administrator has to Log-in before to do any transaction.
The properties of transaction should be maintained at each and every transaction.
Administrator can view the all reports like containing reservation status of various
fields.
Application should provide the multiple Transaction services.
4. Design Considerations
This section describes many of the issues which need to be addressed or resolved before
attempting to devise a complete design solution.
The system used to run the application must support the latest version of
JavaBeans.
Also, the system must have Oracle 10g installed on it.
Back up of the databases in case of hardware failure, disaster, natural calamities.
No data loss in case of handling of the system by the administrators or the system
related personnel.
Page 42 of 123
5. Architectural Strategies
JSP: For interface design JSP will be used. Use various types of controls like text fields,
Label, Check box, List etc. User is going to interact with the jsp pages.
Servlet: It will be used to process the request received from the user. It will be act as
mediator between JSP and JAVA Bean.
Java Bean: The interaction to database will be done through Java bean only. Therefore
to save/retrieve data from the database Java Bean will be used.
JDBC: Database connectivity, Exception Handling, commit/ rollback using JDBC in
order to maintain ACID properties of Transaction.
Oracle: ORACLE is a fourth generation relational database management system. A DBMS must
be secure from unauthorized access and provide efficient solutions for failure recovery. The
ORACLE Server provides efficient and effective solutions for the major database features.
6. System Architecture
JSP:- Java Server Pages (JSP) is a server-side programming technology that enables the
creation of dynamic web pages and applications. This is accomplished by embedding
Java code into HTML, XML, DHTML, or other document types. When a client such as a
web browser makes a request to the Java application container, which is typically a web
server, the static page is converted behind the scenes, and displayed as dynamic content
to the viewer. It has been speculated that JSP was released to compete with PHP, a
commonly used open-source programming language.
Page 43 of 123
SERVLET:- A Servlet is a Java class which conforms to the Java Servlet API, a
protocol by which a Java class may respond to HTTP requests. A Servlet is an object that
receives a request and generates a response based on that request. The basic Servlet
package defines Java objects to represent Servlet requests and responses, as well as
objects to reflect the servlet's configuration parameters and execution environment.
MVC ARCHITECTURE
JAVA BEANS: - JavaBeans are reusable software components for Java that can be
manipulated visually in a builder tool. Practically, they are classes written in the Java
programming language conforming to a particular convention. They are used to
encapsulate many objects into a single object (the bean), so that they can be passed
around as a single bean object instead of as multiple individual objects. A JavaBeans is a
Java Object that is serializable, has a nullify constructor, and allows access to properties
using getter and setter methods.
DAO: - The Java Data Access Object (Java DAO) is an important component in business
applications. Business applications almost always need access to data from relational or
object databases and the Java platform offers many techniques for accessing this data.
The oldest and most mature technique is to use the Java Database Connectivity (JDBC)
API, which provides the capability to execute SQL queries against a database and then
fetch the results, one column at a time. Although this API provides everything a
developer needs to access data and to persist application state, it is a cumbersome API to
develop against - which makes a Java DAO code generator particularly useful.
Home : For this we use jsp pages and there are different fields about the project.
About Us: This tab hold the information about project. The main function that are
provided by Enjoy the life are define here.
Contact Us: This page hold the contact information about the developers.
Register Page: This is the JSP page. This is the page that help the user to register for this
site. There are a simple registration form that are filled by the user and after that the user
are register for this site.
Login Page: This is the JSP page. The login page hold the two fields. These are Name,
Password, by using these field validation are provided that the user is authenticated or
not.
Hotel: This is the JSP page and provide all the related details about the hotels to the
viewer.
Flight: This is the JSP page and provide all the related details about the flights to the
viewer.
Bus: This is the JSP page and provide all the related details about the buses to the viewer.
Train: This is the JSP page and provide all the related details about the trains to the
viewer.
Page 45 of 123
8.1 Classification
Kiosk Management System includes mainly three Modules:
Module 1
Module 2
Module 3
8.2 Definition
Module 1
Analysis design & coding of the following modules
Creation of Various Pages regarding Services provided by Administrator as
Railways, Roadways, Airlines and Hotel Reservation
Creation of Users (Administrator, Visitor, Authorized User)
Creation of Databases Relevant to the Application
Design of Dynamic Search Engine of the application to search for the relevant
services on the basis of inputs provided by User.
Kiosk Management System will provide various types of information to the visitor such
as information regarding roadways, railways, airlines and hotel reservation, contact
information, etc.
Module 2
Analysis design & coding of the following modules
Searching of Relevant data from the database as entered by Administrator
Booking/Reservation/Cancel of the Services by logging as an Authorized User
Onscreen confirmation of the Reservation and through report as well
Printing of Copy of Reservation, if cannot be done at that time then can be done
later using some Booking ID, etc.
Module 3
Analysis design & coding of the following modules
Report generation by the Administrator such as day/monthly reports on various
issues for tracking purpose to enhance the services.
Providing Packages/Offers for the Authorized Users, if user is interested then
further information on packages.
Booking/Reservation/Cancel of Packages
8.3 Responsibilities
Some of the most important services are:
Home : For this we use jsp pages and there are different fields about the project.
About Us: This tab hold the information about project. The main function that
are provided by Enjoy the life are define here.
Page 47 of 123
Contact Us: This page hold the contact information about the developers.
Register Page: This is the JSP page. This is the page that help the user to register
for this site. There are a simple registration form that are filled by the user and
after that the user are register for this site.
Login Page: This is the JSP page. The login page hold the two fields. These are
Name, Password, by using these field validation are provided that the user is
authenticated or not.
Hotel: This is the JSP page and provide all the related details about the hotels to
the viewer.
Flight: This is the JSP page and provide all the related details about the flights to
the viewer.
Bus: This is the JSP page and provide all the related details about the buses to the
viewer.
Train: This is the JSP page and provide all the related details about the trains to
the viewer.
8.4 Constraints
Software is limited for distant places .With distant place it may cause difficulties.
Not very high level Software i.e not for the Network communication.
Every Record to be fetch must in Database Table first.
8.5 Composition
This mainly includes three types of user.
Users may be of three types: - Administrator, Authorized User and Visitor.
Administrator provides Login ID and Password to the user.
Authorized User will have access to all the services provided by KMS.
Visitors are unauthorized users who can just view the details that are provided by
Administrator.
DFD
Page 48 of 123
Page 49 of 123
ER Diagram
name
address
Room type
H id
city
H id
state
Room
details
have
Hotel
Pin no
Contact
no
No
of
room
s
No
of
days
No
rooms
email
Book
ing
id
fare
login
book
ha
s
Check
in
passwor
d
login
rol
e
Booke
d by
User
Check
out
fare
have
Booking hotel
Booking
date
of
Total
fare
Booked
user
email
F
name
passwo
rd
L
name
Booki
ng
payme
nt
Payment
id
Booking
id
gender
payment
amoun
t
addres
s
tax
book
Page 50 of 123
Bus
type
F no
sourc
e
Bus no
destina
tion
flight
E
fare
sea
t
sourc
e
descr
iptio
n
bus
No
of
seats
Ac 1
sleeper
Ac 2
train
destina
tion
Ac 3
sourc
e
sto
ppa
ge
B
fare
station
Table name
Description
login
hotel
train_details
flight_details
station
bus_details
room_details
registration
Page 51 of 123
destina
tion
Page 52 of 123
Page 53 of 123
Page 54 of 123
Hoteprocess
Traindetails
Page 55 of 123
Flightdetails
Station
Page 56 of 123
Busdetails
Roomdetails
Registration
Page 57 of 123
8.9 User/Interactions
Home : For this we use jsp pages and there are different fields about the project.
About Us: This tab hold the information about project. The main function that
are provided by Enjoy the life are define here.
Contact Us: This page hold the contact information about the developers.
Register Page: This is the JSP page. This is the page that help the user to register
for this site. There are a simple registration form that are filled by the user and
after that the user are register for this site.
Login Page: This is the JSP page. The login page hold the two fields. These are
Name, Password, by using these field validation are provided that the user is
authenticated or not.
Hotel: This is the JSP page and provide all the related details about the hotels to
the viewer.
Flight: This is the JSP page and provide all the related details about the flights to
the viewer.
Bus: This is the JSP page and provide all the related details about the buses to the
viewer.
Train: This is the JSP page and provide all the related details about the trains to
the viewer
Page 58 of 123
8.10 Resources
Resources used are CSS file, MVC2 Architecture, JDBC, JSP forms, Servlet, Data
Access Object(DAO), Transfer Object (TO).
8.11 Processing
In this we have used MVC2 Architecture, DAO connectivity through Transfer Object,
JSP forms and Servlet are also used for Communication.
Filename
SLOC
1.
hotel_1.jsp
600
2.
home.jsp
152
3.
Adminstrator.jsp
32
4.
admin.jsp
35
5.
adminbus.jsp
43
6.
adminflight.jsp
47
7.
adminhotel.jsp
52
8.
admintrain.jsp
49
9.
buses.jsp
317
10.
flight.jsp
326
11.
trains.jsp
326
Page 59 of 123
12.
register.jsp
296
13
contactus.jsp
45
// admin.jsp
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
#page-background {position:fixed; top:0; left:0; width:100%; height:100%;}
#content {position:relative;left:150; z-index:1; padding:10px;}
</style>
<script type='text/javascript'>
function formValidation()
{
var eid = document.form2.email_id;
var pswd = document.form2.password;
if(ValidateEmail(eid))
{
if(validatePassword(pswd))
{
}return false;
}
}
function ValidateEmail(eid)
{
var mailformat = /^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/;
if(eid.value.match(mailformat))
{
return true;
}
else
{
alert("You have entered an invalid email address!");
eid.focus();
return false;
}
}
Page 60 of 123
function alphanumeric(pswd)
{
var letters = /^[0-9a-zA-Z]+$/;
if(pswd.value.match(letters))
{
return true;
}
else
{
alert('Please input alphanumeric characters only');
pswd.focus();
return false;
}
}
</script>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>
</head>
<body>
<div id="page-background"><img src="./image/bk5.jpg" width="100%"
height="100%"></div>
<div id="content">
<table align="right" >
<tr>
<td valign="top" align="right" width="50"> <a href="./home.jsp"
title="Homepage"><img src="./image/home.jpg" width="50" height="45"></a></td>
</tr>
</table>
<form action="./admin" method="post" name="form2">
<center><img src="./image/ad5.jpg" height="150" width="1100"></center>
<font size="5">
<table align="center">
<pre>
<tr><td> Login Id </td>
<td><input type="text" name="login"> </td></tr>
<tr><td>Password</td>
<td><input type="password" name="password"> </td>
</tr>
<tr>
<td><input type="submit" value="Sign in"></td>
<td><input type="reset" value="Reset"></td>
</tr>
</pre>
Page 61 of 123
</table>
</font>
</form></div>
</body>
</html>
// administrator.jsp
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<script type="text/javascript">
javascript:window.history.forward(1);
</script>
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
#page-background {position:fixed; top:0; left:0; width:100%; height:100%;}
#content {position:relative;left:150; z-index:1; padding:10px;}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>
</head>
<body>
<div id="page-background"><img src="./image/bk5.jpg" width="100%"
height="100%"></div>
<div id="content">
<table align="right" >
<tr>
<td valign="top" align="right" width="50"> <a href="./home.jsp"
title="Homepage"><img src="./image/home.jpg" width="50" height="45"></a></td>
</tr>
<tr>
<td valign="top" align="right" width="50"> <a href="./home.jsp"
title="Logout"><img src="./image/home.jpg" width="50" height="45"></a></td>
</tr>
</table>
<font size="3">
<table align="center">
<tbody>
Page 62 of 123
<pre>
<tc><td>
<a href="./adminbus.jsp"><img src="./image/q5.jpg"
width="150"><br/><center>Buses</center></a>
</td>
</tc>
<tc><td>
<a href="./admintrain.jsp"> <img src="./image/tt4.jpg"
width="150"><br/><center>Trains</center></a>
</td></tc>
<tc><td>
<a href="./adminflight.jsp"><img src="./image/ff.jpg"
width="150"><br/><center>Flights</center></a>
</td></tc>
<tc><td>
<a href="./adminhotels.jsp"> <img src="./image/hh.jpg"
width="150"><br/><center>Hotels</center></a>
</td></tc>
</pre>
</tbody>
</table>
</font>
</div>
</body>
</html>
height="100"
height="100"
height="100"
height="100"
// adminbus.jsp
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
#page-background {position:fixed; top:0; left:0; width:100%; height:100%;}
#content {position:relative;left:150; z-index:1; padding:10px;}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>
</head>
<body>
<div id="page-background"><img src="./image/bk5.jpg" width="100%"
height="100%"></div>
Page 63 of 123
<div id="content">
<table align="right" >
<tr>
<td valign="top" align="right" width="50"> <a href="./home.jsp"
title="Homepage"><img src="./image/home.jpg" width="50" height="45"></a></td>
</tr>
</table>
<form method="post" action="./bus_detailServlet">
<font size="3">
<table align="center">
<tbody>
<pre>
<tc><td>
<a href="./adminbus.jsp"><img src="./image/q5.jpg" height="100"
width="150"><br/><center>Buses</center></a>
</td>
</tc>
<tc><td>
<a href="./admintrain.jsp"><img src="./image/tt4.jpg" height="100"
width="150"><br/><center>Trains</center></a>
</td></tc>
<tc><td>
<a href="./adminflight.jsp"><img src="./image/ff.jpg" height="100"
width="150"><br/><center>Flights</center></a>
</td></tc>
<tc><td>
<a href="./adminhotels.jsp"><img src="./image/hh.jpg" height="100"
width="150"><br/><center>Hotels</center></a>
</td></tc>
</pre>
</tbody>
</table>
</font>
<table><tbody>
<TR><TD>
<font size="5"> <h2>Bus Details:</h2> </font>
</TD> </TR>
<TR>
<TD height="25">Bus no</TD>
<TD height="25" width="78%"><input type="text" name="bus_no"> </TD></TR>
<TR>
<TD height="14">No of seats</TD>
<TD height="14" width="78%"><input type="text" name="no_of_seats">
</TD></TR>
Page 64 of 123
<TR>
<TD height="14">Bus type</TD>
<TD height="14" width="78%"><input type="text" name="bus_type">
</TD></TR>
<TR>
<TD height="14">Description</TD>
<TD height="14" width="78%"><input type="text" name="description">
</TD></TR>
<TR>
` <TD height="14">Source</TD>
<TD height="14" width="78%"><input type="text" name="source"> </TD></TR>
<TR>
<TD height="14">Destination</TD>
<TD height="14" width="78%"><input type="text" name="destination">
</TD></TR>
<tr>
<td><input type="submit" value="Submit"</td>
</tr>
</tbody>
</table>
</form>
</div>
</body>
</html>
// admintrain.jsp
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
#page-background {position:fixed; top:0; left:0; width:100%; height:100%;}
#content {position:relative;left:150; z-index:1; padding:10px;}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>
</head>
<body>
Page 65 of 123
Page 66 of 123
<TR>
<TD height="14">Train name</TD>
<TD height="14" width="78%"><input type="text" name="train_name">
</TD></TR>
<TR>
<TD height="14">Source</TD>
<TD height="14" width="78%"><input type="text" name="source"> </TD></TR>
<TR>
<TD height="14">Destination</TD>
<TD height="14" width="78%"><input type="text" name="destination">
</TD></TR>
<TR>
` <TD height="14">Ac1</TD>
<TD height="14" width="78%"><input type="text" name="ac1"> </TD></TR>
<TR>
<TD height="14">Ac2</TD>
<TD height="14" width="78%"><input type="text" name="ac2"> </TD></TR>
<TR>
<TD height="14">Ac3</TD>
<TD height="14" width="78%"><input type="text" name="ac3"> </TD></TR>
<TR>
<TD height="14">Sleeper</TD>
<TD height="14" width="78%"><input type="text" name="sleeper"> </TD></TR>
<tr>
<td><input type="submit" value="Submit"</td>
</tr>
</tbody>
</table>
</form>
</div>
</body>
</html>
//adminhotels.jsp
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
#page-background {position:fixed; top:0; left:0; width:100%; height:100%;}
#content {position:relative;left:150; z-index:1; padding:10px;}
Page 67 of 123
</style>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>
</head>
<body>
<div id="page-background"><img src="./image/bk5.jpg" width="100%"
height="100%"></div>
<div id="content">
<table align="right" >
<tr>
<td valign="top" align="right" width="50"> <a href="./home.jsp"
title="Homepage"><img src="./image/home.jpg" width="50" height="45"></a></td>
</tr>
</table>
<form method="post" action="./hotelServlet">
<font size="3">
<table align="center">
<tbody>
<pre>
<tc><td>
<a href="./adminbus.jsp"><img src="./image/q5.jpg"
width="150"><br/><center>Buses</center></a>
</td>
</tc>
<tc><td>
<a href="./admintrain.jsp"><img src="./image/tt4.jpg"
width="150"><br/><center>Trains</center></a>
</td></tc>
<tc><td>
<a href="./adminflight.jsp"><img src="./image/ff.jpg"
width="150"><br/><center>Flights</center></a>
</td></tc>
<tc><td>
<a href="./adminhotels.jsp"><img src="./image/hh.jpg"
width="150"><br/><center>Hotels</center></a>
</td></tc>
</pre>
</tbody>
</table>
</font>
<table><tbody>
<TR>
<TD>
<font size="5"> <h2>Hotel Details:</h2></font>
</TD>
Page 68 of 123
height="100"
height="100"
height="100"
height="100"
</TR>
<TR>
<TD height="14">Hotel id</TD>
<TD height="14" width="78%"><input type="text" name="hotel_id">
</TD></TR>
<TR>
<TD height="14">Hotel Name</TD>
<TD height="14" width="78%"><input type="text" name="hotel_name">
</TD></TR>
<TR>
<TD height="14">Address</TD>
<TD height="14" width="78%"><input type="text" name="address"> </TD></TR>
<TR>
<TD height="14">City</TD>
<TD height="14" width="78%"><input type="text" name="city"> </TD></TR>
<TR>
` <TD height="14">Country</TD>
<TD height="14" width="78%"><input type="text" name="country"> </TD></TR>
<TR>
<TD height="14">Pin Code </TD>
<TD height="14" width="78%"><input type="text" name="pin_no"> </TD></TR>
<TR>
<TD height="14">Contact no</TD>
<TD height="14" width="78%"><input type="text" name="contact_no">
</TD></TR>
<TR>
<TD height="14">Email id</TD>
<TD height="14" width="78%"><input type="text" name="email_id">
</TD></TR>
<tr>
<td><input type="submit" value="Submit"</td>
</tr>
</tbody>
</table>
</form>
</div>
</body>
</html>
// adminflight.jsp
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
Page 69 of 123
<html>
<head>
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
#page-background {position:fixed; top:0; left:0; width:100%; height:100%;}
#content {position:relative;left:150; z-index:1; padding:10px;}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>
</head>
<body>
<div id="page-background"><img src="./image/bk5.jpg" width="100%"
height="100%"></div>
<div id="content">
<table align="right" >
<tr>
<td valign="top" align="right" width="50"> <a href="./home.jsp"
title="Homepage"><img src="./image/home.jpg" width="50" height="45"></a></td>
</tr>
</table>
<form method="post" action="./flight_detailServlet">
<font size="3">
<table align="center">
<tbody>
<pre>
<tc><td>
<a href="./adminbus.jsp"><img src="./image/q5.jpg"
width="150"><br/><center>Buses</center></a>
</td>
</tc>
<tc><td>
<a href="./admintrain.jsp"><img src="./image/tt4.jpg"
width="150"><br/><center>Trains</center></a>
</td></tc>
<tc><td>
<a href="./adminflight.jsp"><img src="./image/ff.jpg"
width="150"><br/><center>Flights</center></a>
</td></tc>
<tc><td>
<a href="./adminhotels.jsp"><img src="./image/hh.jpg"
width="150"><br/><center>Hotels</center></a>
</td></tc>
</pre>
Page 70 of 123
height="100"
height="100"
height="100"
height="100"
</tbody>
</table>
</font>
<table>
<tbody>
<TR><TD>
<font size="5"> <h2>Flight Details:</h2></font>
</TD></TR>
<TR>
<TD height="14">Flight no</TD>
<TD height="14" width="78%"><input type="text" name="flight_no">
</TD></TR>
<TR>
<TD height="14">Source</TD>
<TD height="14" width="78%"><input type="text" name="source"> </TD></TR>
<TR>
<TD height="14">Destination</TD>
<TD height="14" width="78%"><input type="text" name="destination">
</TD></TR>
<TR>
<TD height="14">Business Seat</TD>
<TD height="14" width="78%"><input type="text" name="b_seat"> </TD></TR>
<TR>
` <TD height="14">Economy Seat</TD>
<TD height="14" width="78%"><input type="text" name="e_seat"> </TD></TR>
<TR>
<TD height="14">Business Fare </TD>
<TD height="14" width="78%"><input type="text" name="b_fare"> </TD></TR>
<TR>
<TD height="14">Economy Fare</TD>
<TD height="14" width="78%"><input type="text" name="e_fare"> </TD></TR>
<tr>
<td><input type="submit" value="Submit"</td>
</tr>
</tbody>
</table>
</form>
</div>
</body>
</html>
//adminbus_detailDao.java
Page 71 of 123
ackage com.kms.mvc.DAO;
import com.kms.mvc.bean.bus_detailbean;
import java.sql.*;
import java.util.*;
public class adminbus_detailDao {
public int addbus_detail(bus_detailbean bean)throws Exception
{
Connection conn = connectionDao.getConnection();
CallableStatement cs=conn.prepareCall("{call prcbus_detail(?,?,?,?,?,?)}");
cs.setString(1,bean.getBus_no());
cs.setString(2,bean.getNo_of_seats());
cs.setString(3,bean.getBus_type());
cs.setString(4,bean.getDescription());
cs.setString(5,bean.getSource());
cs.setString(6,bean.getDestination());
return cs.executeUpdate();
}
}
//bus_detailServlet.java
package com.kms.mvc.controller;
import com.kms.mvc.DAO.adminbus_detailDao;
import com.kms.mvc.bean.*;
import java.io.IOException;
import java.io.PrintWriter;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
/**
*
* @author charu
*/
public class bus_detailServlet extends HttpServlet {
private String msg;
protected void processRequest(HttpServletRequest request, HttpServletResponse
response)
throws ServletException, IOException {
String msg=null;
bus_detailbean bean=new bus_detailbean();
bean.setBus_no(request.getParameter("bus_no"));
Page 72 of 123
bean.setNo_of_seats(request.getParameter("no_of_seats"));
bean.setBus_type(request.getParameter("bus_type"));
bean.setDescription(request.getParameter("description"));
bean.setSource(request.getParameter("source"));
bean.setDestination(request.getParameter("destination"));
adminbus_detailDao Dao=new adminbus_detailDao();
try{
int result=Dao.addbus_detail(bean);
if(result>0)
{
msg="success !!!!!!";
}
}catch(Exception ex)
{
msg=ex.getMessage();
System.out.println(ex);
}
finally {
request.setAttribute("msg",msg);
request.getRequestDispatcher("./adminbus.jsp").forward(request,response);
}
}
// <editor-fold defaultstate="collapsed" desc="HttpServlet methods. Click on the +
sign on the left to edit the code.">
/**
* Handles the HTTP <code>GET</code> method.
* @param request servlet request
* @param response servlet response
* @throws ServletException if a servlet-specific error occurs
* @throws IOException if an I/O error occurs
*/
@Override
protected void doGet(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
processRequest(request, response);
}
/**
* Handles the HTTP <code>POST</code> method.
* @param request servlet request
* @param response servlet response
* @throws ServletException if a servlet-specific error occurs
* @throws IOException if an I/O error occurs
*/
Page 73 of 123
@Override
protected void doPost(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
processRequest(request, response);
}
/**
* Returns a short description of the servlet.
* @return a String containing servlet description
*/
@Override
public String getServletInfo() {
return "Short description";
}// </editor-fold>
}
//home.jsp
html>
<head>
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
#page-background {position:fixed; top:0; left:0; width:100%; height:100%;}
#content {position:relative;left:150; z-index:1; padding:10px;}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Home page</title>
</head>
<body background = "./image/homebg.jpg">
<font color="white" size="5">
<script type="text/javascript">
var d = new Date();
var time = d.getHours();
if (time < 10)
{document.write("<b><I>Hello :)Good morning</I></b>");}
else{document.write("<b><I> Hello!! Have a Good day ahead:)</I></b>");}
</script>
<script type="text/javascript">
var d = new Date();
theDay=d.getDay();
switch (theDay)
{case 5: document.write("<b><i>Finally Friday!!!!!</i></b>");
break;
case 6: document.write("<b><i>Super Saturday!!!!!<i></b>");
break;
Page 74 of 123
Page 75 of 123
</th>
<th>
<td height="30" width="50"> <a href="./hotels_1.jsp" title="Hotel
Reservation"><img src="./image/hotel.jpg" width="50" height="45"></a>Hotel</td>
</th>
<th>
<td height="30" width="50">
<a href="./trains.jsp" title="Train Reservation"><img
src="./image/trains.jpg" width="50" height="45"></a>Train</td>
</th>
<th>
<td height="30" width="50">
<a href="./buses.jsp" title="Bus Reservation"><img src="./image/bus.jpg"
width="50" height="45"></a>Bus</td>
</th>
<th>
<td height="30" width="50"> <a href="./gallery.jsp" title="Gallery"><img
src="./image/gallery.jpg" width="50" height="45"></a>Gallery</td>
</th>
<th>
<td height="30" width="50">
<a href="./contactus.jsp" title="Contact Us"><img src="./image/Contact
us.jpg" width="50" height="45"></a>Contact</td>
</th>
<th>
<td height="30" width="50">
<a href="./help.jsp" title="Help!"><img src="./image/help2.jpg"
width="50" height="45"></a>Help</td>
</th>
<th>
<td height="30" width="50">
<a href="./admin.jsp" title="Help!"><img src="./image/help2.jpg"
width="50" height="45"></a>Admin</td>
</th>
</tbody>
</form>
<tbody>
<tr><table align="left">
<marquee behavior="scroll"direction="right" height="250" width="1400">
<img src="./image/home2.jpg" width="300" height="250">
<img src="./image/home3.jpg" width="300" height="250">
<img src="./image/home4.jpg" width="300" height="250">
<img src="./image/home5.jpg" width="300" height="250">
Page 76 of 123
Page 77 of 123
import com.kms.mvc.bean.*;
import java.io.IOException;
import java.io.PrintWriter;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
/**
*
* @author Shikha
*/
public class loginServlet extends HttpServlet {
/**
* Processes requests for both HTTP <code>GET</code> and <code>POST</code>
methods.
* @param request servlet request
* @param response servlet response
* @throws ServletException if a servlet-specific error occurs
* @throws IOException if an I/O error occurs
*/
protected void processRequest(HttpServletRequest request, HttpServletResponse
response)
throws ServletException, IOException {
String msg=null;
try{
loginbean login = new loginbean();
login.setEmail_id(request.getParameter("email_id"));
login.setPassword(request.getParameter("password"));
loginDao dao = new loginDao();
if(dao.validate(login))
{
msg= "User, " + login.getEmail_id();
HttpSession session = request.getSession();
session.setMaxInactiveInterval(60*5);
session.setAttribute("msg", msg);
session.setAttribute("email",login.getEmail_id());
response.sendRedirect("./newjsp.jsp");
}
else
{
msg="Invalid Login ID or Password...";
request.setAttribute("msg", msg);
Page 78 of 123
request.getRequestDispatcher("./home.jsp").forward(request, response);
}
} catch (Exception ex)
{
msg=ex.getMessage();
System.out.println(ex);
}
}
// <editor-fold defaultstate="collapsed" desc="HttpServlet methods. Click on the +
sign on the left to edit the code.">
/**
* Handles the HTTP <code>GET</code> method.
* @param request servlet request
* @param response servlet response
* @throws ServletException if a servlet-specific error occurs
* @throws IOException if an I/O error occurs
*/
@Override
protected void doGet(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
processRequest(request, response);
}
/**
* Handles the HTTP <code>POST</code> method.
* @param request servlet request
* @param response servlet response
* @throws ServletException if a servlet-specific error occurs
* @throws IOException if an I/O error occurs
*/
@Override
protected void doPost(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
processRequest(request, response);
}
/**
* Returns a short description of the servlet.
* @return a String containing servlet description
*/
@Override
public String getServletInfo() {
return "Short description";
}// </editor-fold>
Page 79 of 123
}
loginDao.java
package com.kms.mvc.DAO;
import com.kms.mvc.bean.*;
import java.sql.*;
public class loginDao {
private boolean status;
public boolean validate(loginbean login)throws Exception
{
Connection con = connectionDao.getConnection();
String query= "select email_id,password from registration where email_id=? and
password=?";
PreparedStatement ps = con.prepareStatement(query);
ps.setString(1, login.getEmail_id());
ps.setString(2, login.getPassword());
ResultSet rs = ps.executeQuery();
if(rs.next())
{
if(rs.getString(1).equals(login.getEmail_id()) &&
rs.getString(2).equals(login.getPassword()))
{
status = true;
}
}
con.close();
return status;
}
}
loginbean.java
package com.kms.mvc.bean;
public class loginbean {
private String email_id;
private String password;
private String rol;
public loginbean() {
}
public String getEmail_id() {
return email_id;
}
public void setEmail_id(String email_id) {
Page 80 of 123
this.email_id = email_id;
}
public String getPassword() {
return password;
}
public void setPassword(String password) {
this.password = password;
}
public String getRol() {
return rol;
}
public void setRol(String rol) {
this.rol = rol;
}
}
//trains.jsp
<%@page import="java.util.Iterator"%>
<%@page import="java.util.List"%>
<%@page import="com.kms.mvc.bean.train_detailsbean"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
#page-background {position:fixed; top:0; left:0; width:100%; height:100%;}
#content {position:relative;left:50; z-index:1; padding:10px;}
</style>
</head>
<body>
<div id="page-background"><img src="./image/train1.jpg" width="100%"
height="100%"></div>
<div id="content">
<font color="white"/>
<font size="5" />
<table>
<tc>
<td><img src="./image/logo[1].png" width="200" height="200"><td>
Page 81 of 123
Page 82 of 123
<option
value="AGX">Agatti</option>
<option
value="AGR">Agra</option>
<option
value="AMD">Ahmedabad</option>
<option
value="AJL">Aizawl</option>
<option
value="IXD">Allahabad</option>
<option
value="IXV">Along</option>
<option
value="ATQ">Amritsar</option>
<option
value="IXU">Aurangabad</option>
<option
value="IXB">Bagdogra/Siliguri</option>
<option value="BLR">Bangaluru
(Bangalore)</option>
<option
value="IXG">Belgaum</option>
<option
value="BHU">Bhavnagar</option>
<option
value="BHO">Bhopal</option>
<option
value="BBI">Bhubaneswar</option>
<option
value="BHJ">Bhuj</option>
<option value="CBD">Car
Nicobar</option>
<option
value="IXC">Chandigarh</option>
<option value="MAA">Chennai
(Madras)</option>
<option
value="CJB">Coimbatore</option>
<option
value="CDP">Cuddapah</option>
<option value="DAE">Daporijo
(Daporizo)</option>
<option
value="DED">Dehradun</option>
<option
value="DIB">Dibrugarh</option>
Page 83 of 123
<option
value="DMU">Dimapur</option>
<option value="DIU">Diu</option>
<option
value="IXY">Gandhidham/Kandla</option>
<option
value="GAY">Gaya</option>
<option value="GOI">Goa</option>
<option
value="GAU">Guwahati</option>
<option
value="GWL">Gwalior</option>
<option
value="HBX">Hubli</option>
<option
value="HYD">Hyderabad</option>
<option
value="IMF">Imphal</option>
<option
value="IDR">Indore</option>
<option
value="JLR">Jabalpur</option>
<option
value="JAI">Jaipur</option>
<option
value="JSA">Jaisalmer</option>
<option
value="IXJ">Jammu</option>
<option
value="JGA">Jamnagar</option>
<option
value="JDH">Jodhpur</option>
<option
value="JRH">Jorhat</option>
<option
value="IXH">Kailashahar</option>
<option
value="KNU">Kanpur</option>
<option
value="NAG">Nagpur</option>
<option value="DEL">New Delhi
(Delhi)</option>
<option value="IXI">North
Lakhimpur</option>
<option value="IXT">Pasighat
(Passighat)</option>
Page 84 of 123
<option
value="PAT">Patna</option>
<option
value="PBD">Porbandar</option>
<option value="IXZ">Port
Blair</option>
<option value="PNQ">Pune
(Poona)</option>
<option
value="BEK">Puttaparthi</option>
<option
value="RPR">Raipur</option>
<option
value="RJA">Rajahmundry</option>
<option
value="RAJ">Rajkot</option>
<option
value="IXR">Ranchi</option>
<option
value="SHL">Shillong</option>
<option
value="IXS">Silchar</option>
<option
value="SSE">Sholapur</option>
<option
value="SXR">Srinagar</option>
<option
value="TEZ">Tezpur</option>
<option value="TEI">Tezu</option>
<option
value="TRV">Thiruvananthapuram</option>
<option value="TRZ">Tiruchirapalli
(Trichy)</option>
<option value="TIR">Tirupati
(Tirupathi)</option>
<option value="TCR">Tuticorin
(Thoothukudi)</option>
<option
value="UDR">Udaipur</option>
<option value="BDQ">Vadodara
(Baroda)</option>
<option
value="VNS">Varanasi</option>
<option value="VGA">Vijayawada
(Vijaywada)</option>
Page 85 of 123
<option
value="VTZ">Visakhapatnam (Vishakhapatnam)</option>
<option value="WGC">Warangal
(Warrangal)</option>
</optgroup>
</select></td>
<td height="14" width="100">
<select name="to">
<optgroup label="Top Indian Departure cities">
<option value="BOM">Mumbai
(Bombay)</option>
<option value="delhi">New Delhi
(Delhi)</option>
<option value="MAA">Chennai
(Madras)</option>
<option value="BLR">Bangaluru
(Bangalore)</option>
<option value="goa">Goa</option>
<option value="COK">Kochi
(Cochin)</option>
<option
value="HYD">Hyderabad</option>
<option value="PNQ">Pune
(Poona)</option>
<option value="CCU">Kolkata
(Calcutta)</option>
<option
value="AMD">Ahmedabad</option>
<option
value="ATQ">Amritsar</option>
<option
value="GAU">Guwahati</option>
<option
value="TRV">Thiruvananthapuram</option>
</optgroup>
<optgroup label="Cities in
Alphabetical Order">
<option
value="IXA">Agartala</option>
<option
value="AGX">Agatti</option>
<option
value="AGR">Agra</option>
<option
value="AMD">Ahmedabad</option>
Page 86 of 123
<option
value="AJL">Aizawl</option>
<option
value="IXD">Allahabad</option>
<option
<option
value="TEZ">Tezpur</option>
<option value="TEI">Tezu</option>
<option
value="TRV">Thiruvananthapuram</option>
<option value="TRZ">Tiruchirapalli
(Trichy)</option>
<option value="TIR">Tirupati
(Tirupathi)</option>
<option value="TCR">Tuticorin
(Thoothukudi)</option>
<option
value="UDR">Udaipur</option>
<option value="BDQ">Vadodara
(Baroda)</option>
<option
value="VNS">Varanasi</option>
<option value="VGA">Vijayawada
(Vijaywada)</option>
<option
value="VTZ">Visakhapatnam (Vishakhapatnam)</option>
<option value="WGC">Warangal
(Warrangal)</option>
</optgroup>
</select>
</td>
</tr>
<pre>
<tr>
<td><br><input type="submit" value="Search"/></td>
</tr></pre>
</tbody>
</table>
</form>
<%
if(request.getAttribute("trainList")!=null)
{
Page 87 of 123
Page 88 of 123
<% }else
{
%>
<font color="red"><b>No Record Found</b></font>
<%
}
}
%>
</div>
</body>
</html>
//buses.jsp
<%@page import="java.util.Iterator"%>
<%@page import="com.kms.mvc.bean.bus_detailbean"%>
<%@page import="java.util.List"%>
<%@page contentType="text/html" pageEncoding="UTF-8" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
#page-background {position:fixed; top:0; left:0; width:100%; height:100%;}
#content {position:relative;left:150; z-index:1; padding:10px;}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<font size="5"> <center></center></font>
</head>
<body>
<div id="page-background"><img src="./image/path1.jpg" width="100%"
height="100%"></div>
<div id="content">
<font color="white"/>
<font size="5"/>
<table>
<tc>
<td><img src="./image/logo[1].png" width="200" height="200"><td>
<td> <img src="./image/roadways.jpg" width="1100" height="200"></td>
Page 89 of 123
</tc></table>
<form method="get" action="./busSearch">
<table background="./image/ww1.jpg" width="576" height="288">
<tbody>
<pre> <tr><td><h3> <i><u>Book your tickets now... <u></i></h3><td><tr>
</pre> <th> <tr>
<td height="25" width="80">Leaving</td>
<td height="25" width="80">From</td>
</tr>
</th> <tr>
<td height="14" width="100">
<select name="from">
<optgroup label="Top Indian Departure cities">
<option value="BOM">Mumbai
(Bombay)</option>
<option value="delhi">New Delhi
(Delhi)</option>
<option value="MAA">Chennai
(Madras)</option>
<option value="BLR">Bangaluru
(Bangalore)</option>
<option value="GOI">Goa</option>
<option value="COK">Kochi
(Cochin)</option>
<option
value="HYD">Hyderabad</option>
<option value="PNQ">Pune
(Poona)</option>
<option value="CCU">Kolkata
(Calcutta)</option>
<option
value="AMD">Ahmedabad</option>
<option
value="ATQ">Amritsar</option>
<option
value="GAU">Guwahati</option>
<option
value="TRV">Thiruvananthapuram</option>
</optgroup>
<optgroup label="Cities in
Alphabetical Order">
<option
value="IXA">Agartala</option>
Page 90 of 123
<option
value="AGX">Agatti</option>
<option
value="AGR">Agra</option>
<option
value="AMD">Ahmedabad</option>
<option
value="AJL">Aizawl</option>
<option
value="IXD">Allahabad</option>
<option
value="IXV">Along</option>
<option
value="ATQ">Amritsar</option>
<option
value="IXU">Aurangabad</option>
<option
value="IXB">Bagdogra/Siliguri</option>
<option value="BLR">Bangaluru
(Bangalore)</option>
<option
value="IXG">Belgaum</option>
<option
value="BHU">Bhavnagar</option>
<option
value="BHO">Bhopal</option>
<option
value="BBI">Bhubaneswar</option>
<option
value="BHJ">Bhuj</option>
<option value="CBD">Car
Nicobar</option>
<option
value="IXC">Chandigarh</option>
<option value="MAA">Chennai
(Madras)</option>
<option
value="CJB">Coimbatore</option>
<option
value="CDP">Cuddapah</option>
<option value="DAE">Daporijo
(Daporizo)</option>
<option
value="DED">Dehradun</option>
<option
value="DIB">Dibrugarh</option>
Page 91 of 123
<option
value="DMU">Dimapur</option>
<option value="DIU">Diu</option>
<option
value="IXY">Gandhidham/Kandla</option>
<option
value="GAY">Gaya</option>
<option value="GOI">Goa</option>
<option
value="GAU">Guwahati</option>
<option
value="GWL">Gwalior</option>
<option
value="HBX">Hubli</option>
<option
value="HYD">Hyderabad</option>
<option
value="IMF">Imphal</option>
<option
value="IDR">Indore</option>
<option
value="JLR">Jabalpur</option>
<option
value="JAI">Jaipur</option>
<option
value="JSA">Jaisalmer</option>
<option
value="IXJ">Jammu</option>
<option
value="JGA">Jamnagar</option>
<option
value="JDH">Jodhpur</option>
<option
value="JRH">Jorhat</option>
<option
value="IXH">Kailashahar</option>
<option
value="KNU">Kanpur</option>
<option
value="IXK">Keshod</option>
<option
value="HJR">Khajuraho</option>
<option value="COK">Kochi
(Cochin)</option>
<option
value="KLH">Kolhapur</option>
Page 92 of 123
<option value="CCU">Kolkata
(Calcutta)</option>
<option value="CCJ">Kozhikode
(Calicut)</option>
<option
value="KUU">Kullu/Manali</option>
<option value="IXL">Leh</option>
<option
value="LKO">Lucknow</option>
<option
value="LUH">Ludhiana</option>
<option
value="IXM">Madurai</option>
<option
value="IXE">Mangalore</option>
<option value="BOM">Mumbai
(Bombay)</option>
<option
value="MZU">Muzzafarpur</option>
<option
value="MYQ">Mysore</option>
<option
value="NAG">Nagpur</option>
<option value="DEL">New Delhi
(Delhi)</option>
<option value="IXI">North
Lakhimpur</option>
<option value="IXT">Pasighat
(Passighat)</option>
<option
value="PAT">Patna</option>
<option
value="PBD">Porbandar</option>
<option value="IXZ">Port
Blair</option>
<option value="PNQ">Pune
(Poona)</option>
<option
value="BEK">Puttaparthi</option>
<option
value="RPR">Raipur</option>
<option
value="RJA">Rajahmundry</option>
<option
value="RAJ">Rajkot</option>
Page 93 of 123
<option
value="IXR">Ranchi</option>
<option
value="SHL">Shillong</option>
<option
value="IXS">Silchar</option>
<option
value="SSE">Sholapur</option>
<option
value="SXR">Srinagar</option>
<option
value="TEZ">Tezpur</option>
<option value="TEI">Tezu</option>
<option
value="TRV">Thiruvananthapuram</option>
<option value="TRZ">Tiruchirapalli
(Trichy)</option>
<option value="TIR">Tirupati
(Tirupathi)</option>
<option value="TCR">Tuticorin
(Thoothukudi)</option>
<option
value="UDR">Udaipur</option>
<option value="BDQ">Vadodara
(Baroda)</option>
<option
value="VNS">Varanasi</option>
<option value="VGA">Vijayawada
(Vijaywada)</option>
<option
value="VTZ">Visakhapatnam (Vishakhapatnam)</option>
<option value="WGC">Warangal
(Warrangal)</option>
</optgroup>
</select></td>
<td height="14" width="100">
<select name="to">
<optgroup label="Top Indian Departure cities">
<option value="BOM">Mumbai
(Bombay)</option>
<option value="DEL">New Delhi
(Delhi)</option>
<option value="MAA">Chennai
(Madras)</option>
Page 94 of 123
<option value="BLR">Bangaluru
(Bangalore)</option>
<option value="goa">Goa</option>
<option value="COK">Kochi
(Cochin)</option>
<option
value="HYD">Hyderabad</option>
<option value="PNQ">Pune
(Poona)</option>
<option value="CCU">Kolkata
value="IXG">Belgaum</option>
<option
value="BHU">Bhavnagar</option>
<option
value="BHO">Bhopal</option>
<option
value="BBI">Bhubaneswar</option>
<option
value="BHJ">Bhuj</option>
<option value="CBD">Car
Nicobar</option>
<option
value="IXC">Chandigarh</option>
<option value="MAA">Chennai
(Madras)</option>
<option
value="CJB">Coimbatore</option>
<option
value="CDP">Cuddapah</option>
<option value="DAE">Daporijo
(Daporizo)</option>
<option
value="DED">Dehradun</option>
<option
value="DIB">Dibrugarh</option>
<option
value="DMU">Dimapur</option>
<option value="DIU">Diu</option>
<option
value="IXY">Gandhidham/Kandla</option>
<option
value="GAY">Gaya</option>
<option value="GOI">Goa</option>
<option
<option
value="VTZ">Visakhapatnam (Vishakhapatnam)</option>
Page 95 of 123
<option value="WGC">Warangal
(Warrangal)</option>
</optgroup>
</select>
</td>
</tr>
<td><pre>
<input type="submit" size="200"
align="center"value="Find Buses"/></td>
</pre></tr>
</pre>
</tbody>
</table>
</form>
<%
if(request.getAttribute("busList")!=null)
{
List<bus_detailbean> list =(List<bus_detailbean>)
request.getAttribute("busList");
Iterator<bus_detailbean> it = list.iterator();
if(it.hasNext())
{
%>
<table background="./image/ww1.jpg" border="1">
<thead>
<th>
<tr>
<th>BUS_NO</th>
<th>NO_OF_SEAT</th>
<th>BUS_TYPE</th>
<th>DESCRIPTION</th>
<th>SOURCE</th>
<th>DESTINATION</th>
</th>
</thead>
<tbody>
<%
it = list.iterator();
while(it.hasNext())
{
bus_detailbean bean = it.next();
%>
<tr>
<td><%= bean.getBus_no()%></td>
Page 96 of 123
<td><%=bean.getNo_of_seats()%></td>
<td><%=bean.getBus_type()%></td>
<td><%=bean.getDescription()%></td>
<td><%=bean.getSource()%></td>
<td><%=bean.getDestination()%></td>
<td><a href="./buses1.jsp?bus_no=<%= bean.getBus_no()%>"><font
color="white">Book now</font></a></td>
</tr>
<%
}
%>
</font>
</tbody>
</table>
<% }else
{
%>
<font color="red"><b>No Record Found</b></font>
<%
}
}
%>
</div>
</body>
</html>
Bus_detailSevlet.java
Bus_detailDao.java
trainbean.java
//flight.jsp
<%@page import="java.util.Iterator"%>
<%@page import="com.kms.mvc.bean.flight_detailbean"%>
<%@page import="java.util.List"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
Page 97 of 123
Page 98 of 123
<option
value="HYD">Hyderabad</option>
<option value="PNQ">Pune
(Poona)</option>
<option value="CCU">Kolkata
(Calcutta)</option>
<option
value="AMD">Ahmedabad</option>
<option
value="ATQ">Amritsar</option>
<option
value="GAU">Guwahati</option>
<option
value="TRV">Thiruvananthapuram</option>
</optgroup>
<optgroup label="Cities in
Alphabetical Order">
<option
value="IXA">Agartala</option>
<option
value="AGX">Agatti</option>
<option
value="AGR">Agra</option>
<option
value="AMD">Ahmedabad</option>
<option
value="AJL">Aizawl</option>
<option
value="IXD">Allahabad</option>
<option
value="IXV">Along</option>
<option
value="ATQ">Amritsar</option>
<option
value="IXU">Aurangabad</option>
<option
value="IXB">Bagdogra/Siliguri</option>
<option value="BLR">Bangaluru
(Bangalore)</option>
<option
value="IXG">Belgaum</option>
<option
value="BHU">Bhavnagar</option>
<option
value="BHO">Bhopal</option>
Page 99 of 123
<option
value="BBI">Bhubaneswar</option>
<option
value="BHJ">Bhuj</option>
<option value="CBD">Car
Nicobar</option>
<option
value="IXC">Chandigarh</option>
<option value="MAA">Chennai
(Madras)</option>
<option
value="CJB">Coimbatore</option>
<option
value="CDP">Cuddapah</option>
<option value="DAE">Daporijo
(Daporizo)</option>
<option
value="DED">Dehradun</option>
<option
value="DIB">Dibrugarh</option>
<option
value="DMU">Dimapur</option>
<option value="DIU">Diu</option>
<option
value="IXY">Gandhidham/Kandla</option>
<option
value="GAY">Gaya</option>
<option value="GOI">Goa</option>
<option
value="GAU">Guwahati</option>
<option
value="GWL">Gwalior</option>
<option
value="HBX">Hubli</option>
<option
value="HYD">Hyderabad</option>
<option
value="IMF">Imphal</option>
<option
value="IDR">Indore</option>
<option
value="JLR">Jabalpur</option>
<option
value="JAI">Jaipur</option>
<option
value="JSA">Jaisalmer</option>
<option
value="IXJ">Jammu</option>
<option
value="JGA">Jamnagar</option>
<option
value="JDH">Jodhpur</option>
<option
value="JRH">Jorhat</option>
<option
value="IXH">Kailashahar</option>
<option
value="KNU">Kanpur</option>
<option
value="IXK">Keshod</option>
<option
value="HJR">Khajuraho</option>
<option value="COK">Kochi
(Cochin)</option>
<option
value="KLH">Kolhapur</option>
<option value="CCU">Kolkata
(Calcutta)</option>
<option value="CCJ">Kozhikode
(Calicut)</option>
<option
value="KUU">Kullu/Manali</option>
<option value="IXL">Leh</option>
<option
value="LKO">Lucknow</option>
<option
value="LUH">Ludhiana</option>
<option
value="IXM">Madurai</option>
<option
value="IXE">Mangalore</option>
<option value="BOM">Mumbai
(Bombay)</option>
<option
value="MZU">Muzzafarpur</option>
<option
value="MYQ">Mysore</option>
<option
value="NAG">Nagpur</option>
<option value="DEL">New Delhi
(Delhi)</option>
<option value="IXI">North
Lakhimpur</option>
<option value="IXT">Pasighat
(Passighat)</option>
<option
value="PAT">Patna</option>
<option
value="PBD">Porbandar</option>
<option value="IXZ">Port
Blair</option>
<option value="PNQ">Pune
(Poona)</option>
<option
value="BEK">Puttaparthi</option>
<option
value="RPR">Raipur</option>
<option
value="RJA">Rajahmundry</option>
<option
value="RAJ">Rajkot</option>
<option
value="IXR">Ranchi</option>
<option
value="SHL">Shillong</option>
<option
value="IXS">Silchar</option>
<option
value="SSE">Sholapur</option>
<option
value="SXR">Srinagar</option>
<option
value="TEZ">Tezpur</option>
<option value="TEI">Tezu</option>
<option
value="TRV">Thiruvananthapuram</option>
<option value="TRZ">Tiruchirapalli
(Trichy)</option>
<option value="TIR">Tirupati
(Tirupathi)</option>
<option value="TCR">Tuticorin
(Thoothukudi)</option>
<option
value="UDR">Udaipur</option>
<option value="BDQ">Vadodara
(Baroda)</option>
<option
value="VNS">Varanasi</option>
<option value="VGA">Vijayawada
(Vijaywada)</option>
<option
value="VTZ">Visakhapatnam (Vishakhapatnam)</option>
<option value="WGC">Warangal
(Warrangal)</option>
</optgroup>
</select></td>
<td height="14" width="100">
<select name="to">
<optgroup label="Top Indian Departure cities">
<option value="mumbai">Mumbai
(Bombay)</option>
<option value="DEL">New Delhi
(Delhi)</option>
<option value="MAA">Chennai
(Madras)</option>
<option value="BLR">Bangaluru
(Bangalore)</option>
<option value="goa">Goa</option>
<option value="COK">Kochi
(Cochin)</option>
<option
value="HYD">Hyderabad</option>
<option value="PNQ">Pune
(Poona)</option>
<option value="CCU">Kolkata
(Calcutta)</option>
<option
value="AMD">Ahmedabad</option>
<option
value="ATQ">Amritsar</option>
<option
value="GAU">Guwahati</option>
<option
value="TRV">Thiruvananthapuram</option>
</optgroup>
<optgroup label="Cities in
Alphabetical Order">
<option
value="IXA">Agartala</option>
<option
value="AGX">Agatti</option>
<option
value="AGR">Agra</option>
<option
value="AMD">Ahmedabad</option>
<option
value="AJL">Aizawl</option>
<option
value="IXD">Allahabad</option>
<option
value="IXV">Along</option>
<option
value="ATQ">Amritsar</option>
<option
value="IXU">Aurangabad</option>
<option
value="IXB">Bagdogra/Siliguri</option>
<option value="BLR">Bangaluru
(Bangalore)</option>
<option
value="IXG">Belgaum</option>
<option
value="BHU">Bhavnagar</option>
<option
value="BHO">Bhopal</option>
<option
value="BBI">Bhubaneswar</option>
<option
value="BHJ">Bhuj</option>
<option value="CBD">Car
Nicobar</option>
<option
value="IXC">Chandigarh</option>
<option value="MAA">Chennai
(Madras)</option>
<option
value="CJB">Coimbatore</option>
<option
value="CDP">Cuddapah</option>
<option value="DAE">Daporijo
(Daporizo)</option>
<option
value="DED">Dehradun</option>
<option
value="DIB">Dibrugarh</option>
<option
value="DMU">Dimapur</option>
<option value="DIU">Diu</option>
<option
value="IXY">Gandhidham/Kandla</option>
<option
value="GAY">Gaya</option>
<option value="GOI">Goa</option>
<option
value="GAU">Guwahati</option>
<option
value="GWL">Gwalior</option>
<option
value="HBX">Hubli</option>
<option
value="HYD">Hyderabad</option>
<option
value="IMF">Imphal</option>
<option
value="IDR">Indore</option>
<option
value="JLR">Jabalpur</option>
<option
value="JAI">Jaipur</option>
<option
value="JSA">Jaisalmer</option>
<option
value="IXJ">Jammu</option>
<option
value="JGA">Jamnagar</option>
<option
value="JDH">Jodhpur</option>
<option
value="JRH">Jorhat</option>
<option
value="IXH">Kailashahar</option>
<option
value="KNU">Kanpur</option>
<option
value="IXK">Keshod</option>
<option
value="HJR">Khajuraho</option>
<option value="COK">Kochi
(Cochin)</option>
<option
value="KLH">Kolhapur</option>
<option value="CCU">Kolkata
(Calcutta)</option>
<option value="CCJ">Kozhikode
(Calicut)</option>
<option
value="KUU">Kullu/Manali</option>
<option value="IXL">Leh</option>
<option
value="LKO">Lucknow</option>
<option
value="LUH">Ludhiana</option>
<option
value="IXM">Madurai</option>
<option
value="IXE">Mangalore</option>
<option value="BOM">Mumbai
(Bombay)</option>
<option
value="MZU">Muzzafarpur</option>
<option
value="MYQ">Mysore</option>
<option
value="NAG">Nagpur</option>
<option value="DEL">New Delhi
(Delhi)</option>
<option value="IXI">North
Lakhimpur</option>
<option value="IXT">Pasighat
(Passighat)</option>
<option
value="PAT">Patna</option>
<option
value="PBD">Porbandar</option>
<option value="IXZ">Port
Blair</option>
<option value="PNQ">Pune
(Poona)</option>
<option
value="BEK">Puttaparthi</option>
<option
value="RPR">Raipur</option>
<option
value="RJA">Rajahmundry</option>
<option
value="RAJ">Rajkot</option>
<option
value="IXR">Ranchi</option>
<option
value="SHL">Shillong</option>
<option
value="IXS">Silchar</option>
<option
value="SSE">Sholapur</option>
<option
value="SXR">Srinagar</option>
<option
value="TEZ">Tezpur</option>
<option value="TEI">Tezu</option>
<option
value="TRV">Thiruvananthapuram</option>
<option value="TRZ">Tiruchirapalli
(Trichy)</option>
<option value="TIR">Tirupati
(Tirupathi)</option>
<option value="TCR">Tuticorin
(Thoothukudi)</option>
<option
value="UDR">Udaipur</option>
<option value="BDQ">Vadodara
(Baroda)</option>
<option
value="VNS">Varanasi</option>
<option value="VGA">Vijayawada
(Vijaywada)</option>
<option
value="VTZ">Visakhapatnam (Vishakhapatnam)</option>
<option value="WGC">Warangal
(Warrangal)</option>
</optgroup>
</select>
</td>
</tr>
<tr>
<td><pre>
<input type="submit" value="Find Fights"></pre></td>
</tr>
</tbody>
</table>
</form>
<%
if(request.getAttribute("flightList")!=null)
{
List<flight_detailbean> list =(List<flight_detailbean>)
request.getAttribute("flightList");
Iterator<flight_detailbean> it = list.iterator();
if(it.hasNext())
{
%>
<table border="1">
<thead>
<tr>
<th>FLIGHT_NO</th>
<th>SOURCE</th>
<th>DESTINATION</th>
<th>B_SEAT</th>
<th>E_SEAT</th>
<th>B_FARE</th>
<th>E_FARE</th>
</tr>
</thead>
<tbody>
<%
it = list.iterator();
while(it.hasNext())
{
flight_detailbean bean = it.next();
%>
<tr>
<td><%= bean.getFlight_no()%></td>
<td><%=bean.getSource()%></td>
<td><%=bean.getDestination()%></td>
<td><%=bean.getB_seat()%></td>
<td><%=bean.getE_seat()%></td>
<td><%=bean.getB_fare()%></td>
<td><%=bean.getE_fare()%></td>
<td><a href="./flight1.jsp?flight_no=<%= bean.getFlight_no()
%>">view</a></td>
</tr>
<%
}
%>
</tbody>
</table>
<% }else
{
%>
<font color="red"><b>No Record Found</b></font>
<%
}
}
%>
</div>
</body>
</html>
//hotel_1.jsp
<%@page import="java.util.Iterator"%>
<%@page import="java.util.List"%>
<%@page import="com.kms.mvc.bean.hotelbean"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<html>
<head>
<style type="text/css">
html, body {height:100%; margin:0; padding:0;}
#page-background {position:fixed; top:0; left:0; width:100%; height:100%;}
#content {position:relative; z-index:1; padding:10px;}
</style>
</head>
<title>HOTEL BOOKING</title>
<body>
<div id="page-background"><img src="./image/b4.jpg" width="100%"
height="100%"></div>
<div id="content">
<p align="center"><img src="./image/b7.jpg" height="300" width="1000"></p>
<br>
<option value="Guadeloupe"
>Guadeloupe</option>
<option value="Guam" >Guam</option>
<option value="Guatemala" >Guatemala</option>
<option value="Guinea" >Guinea</option>
<option value="Guinea-bissau" >Guineabissau</option>
<option value="Guyana" >Guyana</option>
<option value="Haiti" >Haiti</option>
<option value="Heard and Mc Donald Islands"
>Heard and Mc Donald Islands</option>
<option value="Honduras" >Honduras</option>
<option value="Hong Kong" >Hong
Kong</option>
<option value="Hungary" >Hungary</option>
<option value="Iceland" >Iceland</option>
<option value="India" >India</option>
<option value="Indonesia" >Indonesia</option>
<option value="Iran (Islamic Republic of)" >Iran
(Islamic Republic of)</option>
<option value="Iraq" >Iraq</option>
<option value="Ireland" >Ireland</option>
<option value="Israel" >Israel</option>
<option value="Italy" >Italy</option>
<option value="Jamaica" >Jamaica</option>
<option value="Japan" >Japan</option>
<option value="Jersey" >Jersey</option>
<option value="Jordan" >Jordan</option>
<option value="Kazakhstan"
>Kazakhstan</option>
<option value="Kenya" >Kenya</option>
<option value="Kiribati" >Kiribati</option>
<option value="Korea, Democratic People's
Republic of" >Korea, Democratic People's Republic of</option>
<option value="Korea, Republic of" >Korea,
Republic of</option>
<option value="Kuwait" >Kuwait</option>
<option value="Kyrgyzstan" >Kyrgyzstan</option>
<option value="Lao People's Democratic Republic"
>Lao People's Democratic Republic</option>
<option value="Latvia" >Latvia</option>
<option value="Lebanon" >Lebanon</option>
<option value="Lesotho" >Lesotho</option>
<option value="Liberia" >Liberia</option>
<option value="Libyan Arab Jamahiriya" >Libyan
Arab Jamahiriya</option>
<option value="Liechtenstein"
>Liechtenstein</option>
<option value="Lithuania" >Lithuania</option>
<option value="Luxembourg"
>Luxembourg</option>
<option value="Macau" >Macau</option>
<option value="Macedonia, The Former Yugoslav
Republic of" >Macedonia, The Former Yugoslav Republic of</option>
<option value="Madagascar"
>Madagascar</option>
<option value="Malawi" >Malawi</option>
<option value="Malaysia" >Malaysia</option>
<option value="Maldives" >Maldives</option>
<option value="Mali" >Mali</option>
<option value="Malta" >Malta</option>
<option value="Marshall Islands" >Marshall
Islands</option>
<option value="Martinique" >Martinique</option>
<option value="Mauritania" >Mauritania</option>
<option value="Mauritius" >Mauritius</option>
<option value="Mayotte" >Mayotte</option>
<option value="Mexico" >Mexico</option>
<option value="Micronesia, Federated States of"
>Micronesia, Federated States of</option>
<option value="Moldova, Republic of" >Moldova,
Republic of</option>
<option value="Monaco" >Monaco</option>
<option value="Mongolia" >Mongolia</option>
<option value="Montserrat" >Montserrat</option>
<option value="Morocco" >Morocco</option>
<option value="Mozambique"
>Mozambique</option>
<option value="Myanmar" >Myanmar</option>
<option value="Namibia" >Namibia</option>
<option value="Nauru" >Nauru</option>
<option value="Nepal"
selected="selected">Nepal</option>
<option value="Netherlands"
>Netherlands</option>
<option value="Netherlands Antilles" >Netherlands
Antilles</option>
<option value="New Caledonia" >New
Caledonia</option>
<option value="New Zealand" >New
Zealand</option>
<option value="Nicaragua" >Nicaragua</option>
</tr>
</table></td>
</tr>
<tr>
<td height="30">Mobile (Optional)</td>
<td><input name="mobile" type="text" id="mobile" size="50" /></td>
</tr>
<tr>
<td height="30">E-mail</td>
<td><input name="email" type="text" id="email" size="50" /></td>
</tr>
<tr>
<td height="30">Category Of Hotel</td>
<td><input name="category[]" type="checkbox" value="5 Star" />
5 Star
<input name="category[]" type="checkbox" value="4 Star" />
4 Star
<input name="category[]" type="checkbox" value="3 Star" />
3 Star
<input name="category[]" type="checkbox" value="2 Star" />
2 Star
<input name="category[]" type="checkbox" value="Standard" />
Standard
<input name="category[]" type="checkbox" value="Budget" />
Budget
</td>
</tr>
<tr>
<td height="30">Category Of Room</td>
<td><input name="room[]" type="checkbox" value="Normal" />
Normal
<input name="room[]" type="checkbox" value="Standard" />
Standard
<input name="room[]" type="checkbox" value="Deluxe" />
Deluxe
<input name="room[]" type="checkbox" value="Suite" />
Suite </td>
</tr>
<tr>
<td height="30">No. of Room Required</td>
<td>Single
<select name="single" id="single">
<option value="0">0</option>
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
<option value="6">6</option>
<option value="7">7</option>
<option value="8">8</option>
<option value="9">9</option>
<option value="10">10</option>
<option value="11">11</option>
<option value="12">12</option>
</select>
Double
<select name="double" id="double">
<option value="0">0</option>
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
<option value="6">6</option>
<option value="7">7</option>
<option value="8">8</option>
<option value="9">9</option>
<option value="10">10</option>
<option value="11">11</option>
<option value="12">12</option>
</select>
Twin Double
<select name="twin_double" id="twin_double">
<option value="0">0</option>
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
<option value="6">6</option>
<option value="7">7</option>
<option value="8">8</option>
<option value="9">9</option>
<option value="10">10</option>
<option value="11">11</option>
<option value="12">12</option>
</select>
Triple
<select name="triple" id="triple">
<option value="0">0</option>
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
<option value="6">6</option>
<option value="7">7</option>
<option value="8">8</option>
<option value="9">9</option>
<option value="10">10</option>
<option value="11">11</option>
<option value="12">12</option>
</select></td>
</tr>
<tr>
<td height="30">Check In Date</td>
<td><input name="checkin" type="text" id="checkin" size="50"
/></td>
</tr>
<tr>
<td height="30">Check Out Date</td>
<td><input name="checkout" type="text" id="checkout" size="50"
/></td>
</tr>
</font>
<tr>
<td><input type="submit" value="Find Hotels"</td>
</tr>
</table>
</form></div>
<%
if(request.getAttribute("hotelList")!=null)
{
List<hotelbean> list =(List<hotelbean>)
request.getAttribute("hotelList");
Iterator<hotelbean> it = list.iterator();
if(it.hasNext())
{
%>
<table border="1">
<thead>
<tr>
<th>HOTEL_ID</th>
<th>HOTEL_NAME</th>
<th>ADDRESS</th>
<th>CITY</th>
<th>COUNTRY</th>
<th>PIN_NO</th>
<th>CONTACT_NO</th>
<th>EMAIL_ID</th>
</tr>
</thead>
<tbody>
<%
it = list.iterator();
while(it.hasNext())
{
hotelbean bean = it.next();
%>
<tr>
<td><%= bean.getHotel_id()%></td>
<td><%=bean.getHotel_name()%></td>
<td><%=bean.getAddress()%></td>
<td><%=bean.getCity()%></td>
<td><%=bean.getCountry()%></td>
<td><%=bean.getPin_no()%></td>
<td><%=bean.getContact_no()%></td>
<td><%=bean.getEmail_id()%></td>
<td><a href="./viewSheat?hotel_id=<%= bean.getHotel_id()
%>">view</a></td>
</tr>
<%
}
%>
</tbody>
</table>
<% }else
{
%>
<font color="red"><b>No Record Found</b></font>
<%
}
}
%>
</body>
</html>
//hotelDao.java
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.kms.mvc.DAO;
import com.kms.mvc.bean.hotelbean;
import java.sql.*;
import java.util.*;
/**
*
* @author Shikha
*/
public class hotelDao {
public List<hotelbean> getHotelInfo(hotelbean bean) throws Exception
{
Connection con = connectionDao.getConnection();
PreparedStatement ps = con.prepareCall("select * from hr.hotel where city=?");
ps.setString(1, bean.getCity());
ResultSet rs = ps.executeQuery();
List<hotelbean> list = new ArrayList<hotelbean>();
while(rs.next())
{
bean = new hotelbean();
bean.setHotel_id(rs.getString(1));
bean.setHotel_name(rs.getString(2));
bean.setAddress(rs.getString(3));
bean.setCountry(rs.getString(4));
bean.setCity(rs.getString(5));
bean.setPin_no(String.valueOf(rs.getInt(6)));
bean.setContact_no(String.valueOf(rs.getLong(7)));
bean.setEmail_id(rs.getString(8));
list.add(bean);
}
con.close();
return list;
}
System.out.println(ex);
}
finally {
out.close();
}
}
}
//hotelbean.java
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.kms.mvc.bean;
/**
*
* @author Shikha
*/
public class hotelbean {
private String hotel_id;
private String hotel_name;
private String address;
private String city;
private String country;
private String pin_no;
private String contact_no;
private String email_id;
public hotelbean() {
}
public String getAddress() {
return address;
}
public void setAddress(String address) {
this.address = address;
}
public String getCity() {
return city;
}
public void setCity(String city) {
this.city = city;
}
public String getContact_no() {
return contact_no;
}
public void setContact_no(String contact_no) {
this.contact_no = contact_no;
}
public String getCountry() {
return country;
}
public void setCountry(String country) {
this.country = country;
}
public String getEmail_id() {
return email_id;
}
public void setEmail_id(String email_id) {
this.email_id = email_id;
}
public String getHotel_id() {
return hotel_id;
}
public void setHotel_id(String hotel_id) {
this.hotel_id = hotel_id;
}
public String getHotel_name() {
return hotel_name;
}
public void setHotel_name(String hotel_name) {
this.hotel_name = hotel_name;
}
10. Output
Home.jsp
flights.jsp
Page 126 of 123
hotels_1.jsp
trains.jsp
buses.jsp
admin.jsp
adminbus.jsp
// gallery
11.Glossary
JSP: JSP pages are Java Server Pages that compile dynamically into servlets. A JSP is a
text-based document that describes how to process a request to create a response JSP
makes it easier to author pages "by hand" JSP tags for invoking JavaBeans TM
components.
Servlets: Servlet are small programs that execute on the server side of a Web
connection. Just as applets dynamically extend the functionality of a Web browser,
servlets dynamically extend the functionality of a Web server.
HTML :Hypertext used to structure content on a website. Although the HTML
certification contains the means to significantly impact the appearance of the page,
HTML should be used exclusively for structure with CSS used to format the page.
JavaScript: JavaScript is used here for the validations and making project more secure.
it allows to make the dynamic web pages.
CSS: CSS stands for Cascading Style Sheets. This is a document format. This provides
a set of style rules which can be incorporated in a XHTML or HTML document.
12. Bibliography
Bibliography or References must be included in the report according to the format given
in the following examples. References should be cited properly inside the text of the
report
1. BOOK
108AdvancedJava
Head First java
Software Engineering by Pressman (6th Edition)
Java 2Complete Reference(5th Ed 2002)
2. REFERENCES
www.yahoo.com
http://en.wikipedia.org/wiki/
www.google.com
http://developers.sun.com/solaris/articles/javapps.html
www.oracle.com/applications/projects/intro.html
5 Conclusion
Kiosk Management System will provide various types of information to the visitor
such as information regarding roadways, railways, airlines and hotel reservation,
contact information, etc.
6 Checklist
This checklist is to be attached as the last page of the report.
This checklist is to be duly completed by the student and verified by the
Supervisor, Project Coordinator and HOD
1.
Yes / No
2.
Yes / No
3.
Yes / No
4.
Yes / No
Yes / No
(a)
Yes / No
5.
format?
(b) Has it been signed by the Student?
7.
Yes / No
(i).
Yes / No
8.
(ii).
Yes / No
(iii).
Yes / No
(iv).
Yes / No
(v).
Yes / No
Yes / No
work?
9.
10.
Yes / No
Have the References been cited inside the text of the Report?
Yes / No
Yes / No
Yes / No
Declaration by Student
I certify that I have properly verified all the items in the checklist
and ensure that the report is in proper format as specified in the
course handout.
Name:
Place:
Date:
Signature of the Student:
Verification by Supervisor
I have duly verified all the items in the checklist and ensured that the
report is in proper format.
Name:
Place:
Date:
Signature of the Supervisor: