You are on page 1of 55

A

Project Report

On

LUCKNOW METRO GUIDE

Submitted in partial fulfillment of the

requirements for the award of the degree

of

BACHELOR OF COMPUTER APPLICATION

1
CERTIFICATE

Certified that Sudhanshu Yadav (201510101130029), ReshmaParveen (201510101130057),


AakashKumarYadav (201510101130023) has carried out the project work presented in this
report entitled “LMRC” for the award of Bachelor Of Computer Applications from
ShriRamswaroop Memorial University, Uttar Pradesh under my supervision. The report
embodies results of original work, and studies are carried out by the student himself and the
contents of the report do not form the basis for the award of any other degree to the candidate or
to anybody else from this or any other university.

Signature of Supervisor(s)
Name(s)
Department(s)
ShriRamswaroop Memorial University

May, 2018

Signature of Dean
Name(s)
Department(s)
ShriRamswaroop Memorial University

2
ABSTRACT

Lucknow Metro Guide is a web application that is designed with the information related

to the Lucknow Metro trains. This app contains the information related to Metro such as the

number of stations covered by the Train, Metro fare and map. It also contains the details of the

station, nearby places that attracts tourists etc.

This web application is made in such a manner that an end user will find it very easy to use and

find convenient in using lucknow metro. The main purpose of this application is to provide the

complete information about the Lucknow metro to the user who has planned to newly visit

Lucknow or to provide user the right information of the stations nearby, hence this web

application is mainly targeted to only one module that is the user module.

The designing of the website is done in such a way so as to make it easier for the passenger to

search for the right train to the station fare of the train this application is made to facilitate the

user.

3
ACKNOWLEDGEMENT

It gives a great pleasure to present the report of the "LMRC GUIDE" Project undertaken during
BCA final year. We owe special debt of gratitude to Dr.PromilaBahadur Ma'am, Department of
Computer Application ShriRamswaroop Memorial University for her constant support guidance
throughout the course of our work.
We also take the opportunity to acknowledge the contribution of Professor Mr. Bineet Gupta
Sir, Head of Department of Computer Applications, ShriRamswaroop Memorial University,
Barabanki for his full support and assistance during the development of the project.
We also do not like to miss the opportunity to acknowledge the contribution of all faculty
members of their department for their kind assistance and cooperation during the development of
the project. Last but not least, we acknowledge our friends for their
contribution in the completion of the project.

SUDHANSHU YADAV
RESHMA PARVEEN
AKASH KUMAR YADAV

4
DECLARATION

We hereby declare that the project entitled “LMRC GUIDE” submitted by us in the partial
fulfilment of the requirements for the award of the degree ofBachelor of Computer Application
of ShriRamswaroop Memorial University, DewaRoad Barabanki is record of our own work
carried under the supervision of Ms. Priyanka Gupta (Assistant Professor).

To the best of our knowledge this project has not been submitted to ShriRamswaroop
Memorial University, Dewa Road Barabankior any other University or Institute
For the award of any degree.

Supervisor
Ms. Privanka Gupta
Asstt. Professor

SUDHANSHU YADAV

RESHMA PARVEEN

AKASH KUMAR YADAV

Date :-………………..

Place :-……………….

5
TABLE OF CONTENT

S.No. TOPIC Page No.


CERTIFICATE I
DECLARATION II
ACKNOWLEDGEMENT III
ABSTRACT IV

1. INTRODUCTION 2-3
1.1 OBJECTIVE 4
1.2 SYSTEM REQUIREMENT & ANALYSIS 4-6
1.3 MODULE DESCRIPTION 7-8
1.4 SYSTEM DESIGN 8-9

2. E-R DIAGRAM 11
2.1 DFD 12

3. SOFTWARE & HARDWARE REQUIREMENT 14


3.1 LOW LEVEL DESIGN 15
3.2 SNAP SHOTS 16-26

4. IMPLIMENTATION 28
4.1 CODING 29-43

5. ADVANTAGES 45
5.1 CONCLUSION 46
5.2 FUTURE SCOPE 47
6. REFERENCES 48

6
LIST OF FIGURES

S. No. TOPIC Page No.

1. 2.ER-DIAGRAM

i. Figure 1.1 11

2. 2.1 DFD

ii. Figure 1.2 12

3. 3.2 Snapshots

iii. INDEX.JSP 16
iv. STATION.JSP 17
v. STATIONSEARCH.JSP 18
vi. FAIR.JSP 19
vii. SEARCHFAIR.JSP 20
viii. MAP.HTML 21
ix. LOGIN.JSP 22
x. DASHBOARD.JSP 23
xi. ADD STATIONS.JSP 24-25
xii. DATABASE 26

7
CHAPTER : 1

8
1. Introduction

The Lucknow Metro is a Mass Rapid Transit System (MRTS) being constructed to provide the

city of Lucknow, Uttar Pradesh with an environment friendly atmosphere. The commencement

of civil works started on 27 September 2014. Lucknow Metro Rail Corporation Limited or

LMRC is working on this project which will be an alternative mode of transport since

approximately 94% of the city's registered vehicles are private, city had over 2 million registered

vehicle in 2015.According to a report every month city is adding about 1000 new four wheelers

in its vehicle population. Growing population and huge traffic has called for the transformation

of private modes of conveyance to public transport.

Lucknow Metro will be having two routes, from North to South and East to West. The

North-South corridor starts at Amausi to MunshiPulia, with a total length of 22.878 kilometers

(14.216 miles). The East-West corridor starts at Charbagh Railway Station and ends at

VasantKunj. Both lines will intersect at Charbagh. An extension line from Indira Nagar – Gomti

Nagar – Polytechnic Crossing will extend it to Patrakarpuram, Gomti Nagar.

So we design this website to facilitate the user and provide them all the information of Lucknow

Metro such as fare and stations .and allow the free access to all the information’s without any

charges.

This website will also help in maintaining a central database for easy references when required.

The project aims at the following matters-

1) It has search module for searching stations and fare.

2) Assistance in decision making.

9
3) It provide the complete information regarding Lucknow Metro.

4) Provides a simple and easy User Interface.

This project comprise of basic three modules which are interconnected. The information LMRC

and user can search on the website for the stations and fare. Without any cost and access the

facility available. The responsibility of the admin includes the verification of the details and the

updating of new routes and fare. The search can be done by anyone.

ADMIN

user

LMRC info

Figure 1-Basic modules

The admin could do the updating in the info and add the maps, new station, and new fares.

This website help will also cover the various aspects such as the distance of the user from the

stations nearby.

10
1.1Objective

This project is aimed at developing a web based application for Lucknow Metro Station

that is provided with the complete information’s.

 To provide the complete information regarding Lucknow metro.

 The user is provided with information regarding the stations.

 The trains route and the fare.

 To display the list of stations and the distance from the user of the station.

1.2System Requirements &Analysis

Existing System :-

 Information cannot be collected, processed and communicated more quickly and

efficiently.

 Current working systems does information reaches the right person at the right

Problem Identification :-

The problem occurred before having online system includes:

 File Lost when online system is not implemented the complaints are reported in files.

The files are always lost due to some human errors.

 Most Updating are unnoticeable when online systems is not implemented any changes

in fair, etc. when updated, the details of these things are only available at the stations.

11
Proposed System :-

The proposed system is designed to eliminate the disadvantages of the existing system.

The proposed system is mentioned for tracing the problems in the existing system -:

 Increased efficiency and reliability.

 Easier Access.

 Easy to use

 Provide accurate information to the user for taking necessary decisions.

 Accuracy- The information will be correct, accurate and unambiguous.

 Efficiency- Information can be collected, processed and communicated more

quickly and efficiently. Systems ensure that right information reaches the right

person at the right time.

 Reliability - Since systems are free from boredom and tiredness, they work

constantly on data to produce more reliable outputs.

 Accessibility, Usability and Understandability

 The options used can be easily accessed, used and realized.

Functional Requirement -:

 Train Concern Requirement: The fare of the train must be updated.

 User Requirement: There is no specific requirement for the user any one could

access the website it is free to all.

 Database Requirement: The admin is mandatory to fill the details that are

compulsory for the verification. It is advisable to complete the database asked so that

he gives and get better result.

12
 Regulatory Requirement: The database will have a calculation and data storage.

The database can be secure with password encryption.

 Information Requirement: Admin has the full control over the activities and is

responsible for updating. User can search and find all details about the trains, stations

and fare’s.

Non-Functional Requirement :-

 Accessibility: This site is accessible by everyone but is of the concern to only those who

wants to know about Metro. The user can search the interested data and also every info

about the train.

 Capacity and Forecast: The capacity is largely dependent on the server and the overload

of the database on the site. The data is handled by VPS with capacity of 80 GB. The

capacity can be extended with the up gradation of the website.

 Documentation: Documentation is necessary part of any report so as to get future

reference, to make the improvement in the current system. This documentation is

developed at every stage of the development of the project

 Efficiency, Effectiveness, Extensibility: The documentation and ease flow of the project

gives the future developer to improvise the website.

 Privacy and Policy: This is in concern to the university that has used the site. It varies

from institution to institution.

 Security and Stability: The security here is the password encryption and stability is in

concern to the input data, verifying and getting proper output.

13
1.3Module Description:-

User Module :-

Description of Feature

This feature allows the users to view the fair and route map. Users are required to enter

the source and destination station, when they enter the data then the system will display fair

details.

Functional Requirements

 System must allow the users to enter the source and destination stations.

System must be able to retrieve information from the database.

Admin Module :-

Overall Description:-

For the Gomti Nagar link, the train coming from the airport terminal was to be diverted

towards Gomti Nagar at the Indira Nagar trisection Polytechnic crossing along an elevated route.

The planned stations were Indira Nagar Trisection, West End Mall [Waves Multiplex], Gomti

Nagar & Patrakarpuram.

The North-South corridor was planned to connect the Lucknow railway station at

Charbagh to Vasantkunj on Hardoi Road and have a total length of 11 km (6.8 mi), including

14
4.29 km elevated (2.67 mi), 0.5 km ramp (0.31 mi) and 6.3 km underground (3.9 mi). This

corridor was to have 12 stations including seven underground and five overhead.

The stations at Lucknow Railway Station (Charbagh), Gautam Buddha Marg, Aminabad,

Pandeyganj, Chattrapati Shahuji Maharaj Medical University (King George Medical University)

and Niwazganj were to be below ground level, and an elevated section for the Thakurganj,

Balaganj, Sarfarazganj, Moosabagh and the Vasant Kunj terminal stations.

The designed speed of metro would be 90 km/h (56 mph) while the scheduled speed would be

34 km/h (21 mph) for North-South corridor and 32 km/h (20 mph) for East-West corridor. There

would be only one depot at Vasant Kunj spread over a land measuring 20 hectares (49 acres).

The Amausi Depot has been done away because of its proximity to the Airport and the

subsequent reasons of security and safety.

1.4 System Design

System design is the solution for the creation of a new system. This phase focuses on the detailed

implementation of the feasible system. It emphasis on translating design. Specifications to

performance specification. System design has two phases of development

1. Logical Design

2. Physical Design

During logical design phase the analyst describes inputs (sources), output s(destinations),

databases (data sores) and procedures (data flows) all in a format that meets the user

requirements. The analyst also specifies the needs of the user at a level that virtually determines

15
the information flow in and out of the system and the data resources. Here the logical design is

done through data flow diagrams and database design. The physical design is followed by

physical design or coding. Physical design produces the working system by defining the design

specifications, which specify exactly what candidate system must do.

16
CHAPTER : 2

17
2. E-R Diagram

Figure - 1.1

18
2.1 DFD

Figure - 1.2

19
CHAPTER : 3

20
3. Software and Hardware Requirement :-

The following are minimum hardware and requirements that should be present to run the project

successfully.

Hardware -

Processor Pentium IV

Hard Disk 120 GB and above

RAM 2 GB and above

Software -

Operating System Windows 10,7 and others

Front End HTML, ASP, CSS & Boot Straps

Back End Java.

Data Base SQL Server2008.

Designing Tool Eclipse IDE

Scripting Language JavaScript and JQuery.

Browser Google, Chrome,Internet Explorer.

21
3.1 Low Level Design

Database Table :-

1. Admin Table:-

Field Type Null Key Default Extra

Name char<45> NO PRI NULL auto_increament

Password varchar<45> NO

22
3.2Snap Shots

Index.jsp :-

Figure - 1.3

23
Stations.jsp:-

Figure - 1.4

24
Stationsearch.jsp :-

Figure – 1.5

25
Fare.jsp :-

Figure - 1.6

26
Searchfair.jsp :-

Figure – 1.7

27
Map.html :-

Figure – 1.8

28
Login.jsp:-

Figure – 1.9

29
Admin Interface :-

Dashboard.jsp :-

Figure – 2

30
Addstation.jsp:-

Figure – 2.1

31
(After add station (id 1006))

Figure – 2.2

32
Database screenshots:-

Figure – 2.3

33
CHAPTER : 4

34
4. Implementation

One of the purposes of the testing is to validate and verify the system. Verification means

checking the system to ensure that it is doing what the function is supposed to do and Validation

means checking to ensure that system is doing what the user wants it to do.

No program or system design is perfect; communication between the user and the

designer is not always complete or clear, and time is usually short. The result is errors and more

errors. Theoretically, a newly designed system should have all the pieces in working order, but in

reality, each piece works independently. Now is the time to put all the pieces into one system and

test it to determine whether it meets the user's requirements. This is the best chance to detect and

correct errors before the system is implemented. The purpose of system testing is to consider all

the likely variations to which it will be subjected and then push the system to its limits. If we

implement the system without proper testing then it might cause the problems.

1. Communication between the user and the designer.

2. The programmer's ability to generate a code that reflects exactly the system specification.

3. The time frame for the design.

35
4.1Coding

Index.jsp:-

<!DOCTYPE html>
<html lang="en"><!--<![endif]-->
<head>

<meta charset="utf-8">
<title>L.M.T.Guide</title>
<meta name="description" content="Free Responsive Html5 Css3 Templates | zerotheme.com">

<link rel="stylesheet" href="../css/zerogrid.css">


<link rel="stylesheet" href="../css/style.css">
<link rel="stylesheet" href="../css/lightbox.css">

<!-- Custom Fonts -->


<link href="../font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css">

<link rel="stylesheet" href="../css/menu.css">


<script src="../js/jquery1111.min.js" type="text/javascript"></script>
<script src="../js/script.js"></script>

</head>

<body>

<div class="wrap-body">
<div class="zerogrid" >
<div class="row" >
<div class="col-1-3">
<center>
<br>
</center>
</div>
<div class="col-1-1">
<center>

36
<h1 class="color-red" style="margin-top:10px; margin-bottom:10px; padding-top:15px;
color:red; font-size:38px; float:left;">Lucknow Metro Train Guide</h1><br><br>
</center>
</div>
<div class="col-1-3">
<h3 class="color-red" ></h3>
</div>
</div>
</div>

<div class="header">
<div id='cssmenu' style="background-color:red;">
<ul>
<li class="active"><a href='index.jsp'><span>Home</span></a></li>
<li><a href='about.html'><span>About</span></a></li>
<li><a href='stations.jsp'><span>Stations</span></a></li>
<li><a href='fare.jsp'><span>Fare</span></a></li>
<li><a href='map.html'><span>Map</span></a></li>
<li><a href='faq.jsp'><span>FAQ</span></a></li>
<li><a href="login.html"><i class="fa fa-user" align="navbar-right"></i></a></li>
</ul>
</div>
</div>
<section id="container">
<div class="wrap-container">
<!-----------------content-box-1-------------------->
<section class="content-box boxstyle-1 box-1">
<div class="zerogrid">
<div class="row wrap-box"><!--Start Box-->
<div class="col-1-2">
<div class="wrap-col">
<center>
<div class="w3-content w3-section" style="max-width:600px">
<img class="mySlides" src="../images/Lucknow_Metro1.jpg" style="width:100%" />
<img class="mySlides" src="../images/Lucknow_Metro2.jpg" style="width:100%" />
<img class="mySlides" src="../images/Lucknow_Metro3.jpg" style="width:100%" />
<img class="mySlides" src="../images/Lucknow_Metro4.jpg" style="width:100%" />
</div>
</center>
</div>
<script>
var myIndex = 0;
carousel();

37
function carousel() {
var i;
var x = document.getElementsByClassName("mySlides");
for (i = 0; i < x.length; i++) {
x[i].style.display = "none";
}
myIndex++;
if (myIndex > x.length) {myIndex = 1}
x[myIndex-1].style.display = "block";
setTimeout(carousel, 2000);
}
</script>
</div>
<div class="col-1-2">
<div class="wrap-col">
<div class="row">
<div class="t-center" style="padding-top: 60px;">
<div class="header">
<div class="wrapper">
<h1><span class="color-red"> Welcome to L.M.T.Guide</span></h1>
</div>
</div>
<p>The Lucknow Metro is a Mass Rapid Transit System (MRTS) being constructed to provide
the city of Lucknow, Uttar Pradesh with an environment friendly atmosphere. The
commencement of civil works started on 27 September 2014. Lucknow Metro Rail Corporation
Limited or LMRC is working on this project which will be an alternative mode of transport since
approximately 94% of the city's registered vehicles are private,city had over 2 million registerd
vehicle in 2015.</p>
<a href="https://en.wikipedia.org/wiki/Lucknow_Metro" class="button" target="_blank" >More
Details</a>
</div>
</div>
</div>
</div>
</div>
<div>
<%@ page import="java.sql.*" %>
<%@page import="javax.sql.*" %>
<%@page import="java.sql.Connection" %>

<form action="stationsearch.jsp" method="post">


<h1><span class="color-red"> Lucknow Metro Route Search </span></h1>
<hr>

38
<p><span style="font-weight:bold; margin-left:5px;">From:</span><br>
<select name="statstation" style="width:100%; height:30px; border-radius: 5px;">
<%
Class.forName("com.mysql.jdbc.Driver");
Connection
con=DriverManager.getConnection("jdbc:mysql://localhost:3306/lmrg","root","root");
Statement st=con.createStatement();
ResultSet rs=st.executeQuery("select * from stations");
%>
<%while(rs.next()){%>
<option value=<%=rs.getString(1)%>><%=rs.getString(2)%>(<%=rs.getString(3)%>)</option>
<%}%>
</select>
</p>

<p><span style="font-weight:bold; margin-left:5px;">TO:</span><br>


<select name="endstation" style="width:100%; height:30px; border-radius: 5px;">
<%
Class.forName("com.mysql.jdbc.Driver");
Connection
conn=DriverManager.getConnection("jdbc:mysql://localhost:3306/lmrg","root","root");
Statement stm=con.createStatement();
ResultSet rst=stm.executeQuery("select * from stations");
%>
<%while(rst.next()){%>
<option
value=<%=rst.getString(1)%>><%=rst.getString(2)%>(<%=rst.getString(3)%>)</option>
<%}%>
</select>
</p>
<input type="submit" value="Show Route"
style="width:250px;height:40px;color:white;background-color:red;border-radius:5px;font-
family:max-height;font-size:15px;">
</form>
</div>
</div>
</section><br>
<!-----------------content-box-2-------------------->
<section class="content-box boxstyle-2 box-2">
<div class="zerogrid">
<div class="row wrap-box"><!--Start Box-->
<div class="header">
<div class="wrapper">

39
<h2 class="color-red">Our Team</h2>
</div>
</div>
<div class="row">
<div class="col-1-2">
<div class="row post">
<div class="col-1-4">
<div class="wrap-col wrapper">
<a href="#"><img src="../images/nadeem.jpeg"></a>
</div>
</div>
<div class="col-3-4">
<div class="wrap-col">
<h3>Nadeem Husain</h3>
<p>His primis omittam intellegat cu, voluptua appetere mea ad, eu harum oporteat vix.Et vel
quod legimus, graeci electram ocurreret at his.</p>
</div>
</div>
</div>

</div>
<div class="col-1-2">
<div class="row post">
<div class="col-1-4 right">
<div class="wrap-col wrapper">
<a </div>
</div>
<div class="col-3-4">
<div class="wrap-col">
</div>
</div>
</div>

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

</div>
</section>
<hr class="line">

40
<!--////////////////////////////////////Footer-->
<footer>
<div class="wrap-footer">
<div class="zerogrid">
<div class="row">
<div class="col-1-3">
<div class="wrap-col">
<p>Copyright - <a
href="http://www.zerotheme.com" target="_blank" rel="nofollow">L.M.T.Guide</a>
designed by SRA</p>
</div>
</div>
<div class="col-1-3">
<div class="wrap-col">
<ul class="social-buttons">
<li><a href="#"><i class="fa fa-twitter"></i></a>
</li>
<li><a href="#"><i class="fa fa-facebook"></i></a>
</li>
<li><a href="#"><i class="fa fa-linkedin"></i></a>
</li>
</ul>
</div>
</div>
<div class="col-1-3">
<div class="wrap-col">
<ul class="quick-link">
<li><a href="#">Privacy Policy</a></li>
<li><a href="#">Terms of Use</a></li>
</ul>
</div>
</div>
</div>
</div>
</div>
</footer>
<script src="js/lightbox-plus-jquery.min.js"></script>
</div>
</body>
</html>

41
Login.jsp -:

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


pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<%@page import="java.sql.ResultSet" %>
<%@page import="java.sql.*" %>
<%@page import="java.io.*" %>
<%@page import="javax.sql.*" %>
<%@page import="java.sql.Connection" %>

<%
String UserName = request.getParameter("name");
String Password = request.getParameter("pass");

Class.forName("com.mysql.jdbc.Driver").newInstance();
Connection con =
DriverManager.getConnection("jdbc:mysql://localhost:3306/lmrg","root","root");
Statement st = con.createStatement();

ResultSet rs = st.executeQuery("select * from admin where adminName='"+UserName+"' and


password='"+Password+"'");
int a=0;
while(rs.next())
a++;
if(a>0)
{
HttpSession logss = request.getSession();
logss.setAttribute("LUN", UserName);
response.sendRedirect("../admin/dashboard.jsp");
}
else
{
PrintWriter outa = response.getWriter();
out.println("<script type=\"text/javascript\">");

42
out.println("alert('User Name or Password is Incorrect, Please Try Again.');");
out.println("location='login.html';");
out.println("</script>");
}

%>
</body>
</html>

Station.jsp :-

<!DOCTYPE html>
<html lang="en"><!--<![endif]-->
<head>

<meta charset="utf-8">
<title>L.M.T.Guide</title>
<meta name="description" content="Free Responsive Html5 Css3 Templates | zerotheme.com">

<link rel="stylesheet" href="../css/zerogrid.css">


<link rel="stylesheet" href="../css/style.css">
<link rel="stylesheet" href="../css/lightbox.css">

<!-- Custom Fonts -->


<link href="../font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css">

<link rel="stylesheet" href="../css/menu.css">


<script src="../js/jquery1111.min.js" type="text/javascript"></script>
<script src="../js/script.js"></script>

</head>

<body>
<div class="wrap-body">
<div class="zerogrid" >
<div class="row" >

43
<div class="col-1-3">
<center>
<br>
</center>
</div>
<div class="col-1-1">
<center>
<h1 class="color-red" style="margin-top:10px; margin-bottom:10px; padding-top:15px;
color:red; font-size:38px; float:left;">Lucknow Metro Train Guide</h1><br><br>
</center>
</div>
<div class="col-1-3">
<h3 class="color-red" ></h3>
</div>
</div>
</div>
<div class="header">
<div id='cssmenu' style="background-color:red;">
<ul>
<li><a href='index.jsp'><span>Home</span></a></li>
<li><a href='about.html'><span>About</span></a></li>
<li class="active"><a href='stations.jsp'><span>Stations</span></a></li>
<li><a href='fare.jsp'><span>Fare</span></a></li>
<li><a href='map.html'><span>Map</span></a></li>
<li><a href='faq.jsp'><span>FAQ</span></a></li>

<li><a href="login.html"><i class="fa fa-user" align="navbar-right"></i></a></li>


</ul>
</div>
</div> <!--////////////////////////////////////Container-->
<section id="container">
<div class="wrap-container">
<!-----------------content-box-2-------------------->

<section class="content-box boxstyle-2 box-2">


<div class="zerogrid">
<div class="row wrap-box"><!--Start Box-->
<div class="header">
<div class="wrapper">
<h2 class="color-red">List of Lucknow Metro Stations</h2>
</div>
</div>
<%@page import="java.sql.*" %>

44
<%@page import="javax.sql.*" %>
<%@page import="java.sql.Connection" %>
<center>
<div class="row">
<div class="col-1-1">
<div class="row post">
<div class="col-1-12">
<div class="wrap-col">
<table style="border-style: solid; border-width: 3px; border-color:red;">
<caption style='background-color:red; padding:5px;'><h6>All Station List</h6></caption>
<tr>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
rowspan='1'>S.No.</th>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
rowspan='1'>Station ID</th>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
rowspan='1'>Station Name</th>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
colspan='1'>Station Code</th>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
colspan='1'>Corridor</th>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
colspan='1'>Distance(m)</th>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
colspan='1'>Contact No</th>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
colspan='1'>Opening Date</th>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
colspan='1'>Near By Places</th>
</tr>
<center>
<%
Class.forName("com.mysql.jdbc.Driver");
Connection
con=DriverManager.getConnection("jdbc:mysql://localhost:3306/lmrg","root","root");
Statement st=con.createStatement();
ResultSet rs=st.executeQuery("select * from stations");
%>
<%int i = 1;while(rs.next()){%>
<tr>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=i%></td>

45
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=rs.getString(1)%></td>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=rs.getString(2)%></td>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=rs.getString(3)%></td>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=rs.getString(4)%></td>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=rs.getString(5)%></td>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=rs.getString(6)%></td>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=rs.getString(7)%></td>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=rs.getString(8)%></td>
</tr>
<%i++;} %>

</table>

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

</div>
</center>
</div>
</div>
</section>

</div>
</section>

<hr class="line">
<!--////////////////////////////////////Footer-->
<footer>
<div class="wrap-footer">
<div class="zerogrid">
<div class="row">

46
<div class="col-1-3">
<div class="wrap-col">
<p>Copyright - <a href="http://www.zerotheme.com" target="_blank"
rel="nofollow">L.M.T.Guide</a> designed by SRA</p>
</div>
</div>
<div class="col-1-3">
<div class="wrap-col">
<ul class="social-buttons">
<li><a href="#"><i class="fa fa-twitter"></i></a>
</li>
<li><a href="#"><i class="fa fa-facebook"></i></a>
</li>
<li><a href="#"><i class="fa fa-linkedin"></i></a>
</li>
</ul>
</div>
</div>
<div class="col-1-3">
<div class="wrap-col">
<ul class="quick-link">
<li><a href="#">Privacy Policy</a></li>
<li><a href="#">Terms of Use</a></li>
</ul>
</div>
</div>
</div>
</div>
</div>
</footer>
</div>
</body>
</html>

47
Stationsearch.jsp :-

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


pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<%@ page import="java.sql.*" %>
<%@page import="javax.sql.*" %>
<%@page import="java.sql.Connection" %>
<%
String SStart = request.getParameter("statstation");
String SEnd = request.getParameter("endstation");

Class.forName("com.mysql.jdbc.Driver");
Connection
con=DriverManager.getConnection("jdbc:mysql://localhost:3306/lmrg","root","root");
Statement st=con.createStatement();
%>

<%

//while(rsStart.next()){
//String SStartName = rsStart.getString("StationName").toString();
//String SEndName = rsStart.getString(1).toString();
//}
%>
<center>
<div class="row">
<div class="col-1-1">
<div class="row post">
<div class="col-1-12">
<div class="wrap-col">
<table style="border-style: solid; border-width: 3px; bordater-color:red;">

<caption style='background-color:red; padding:5px;'><h1>List of Stations From

48
<%ResultSet rsStart = st.executeQuery("SELECT * FROM stations where S_ID='"+SStart+"'");
while(rsStart.next()){ %>
<%=rsStart.getString(2)%><%}%> To
<%ResultSet rsEnd = st.executeQuery("SELECT * FROM stations where S_ID='"+SEnd+"'");
while(rsEnd.next()){ %>
<%=rsEnd.getString(2)%><%}%>
</h1></caption>

<tr>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
rowspan='1'>S.No.</th>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
rowspan='1'>Station Name</th>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
colspan='1'>Distance(m)</th>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
colspan='1'>Contact No</th>
<th style="border:1px solid red; align:left; margin-left:5px; margin-right:5px; padding:5px;"
colspan='1'>Near By Places</th>
</tr>
<center>
<%
ResultSet rs=st.executeQuery("SELECT * FROM stations where S_ID between '"+SStart+"' and
'"+SEnd+"'");
int i = 0;
while(rs.next()){
i++;
%>
<tr>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=i%></td>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=rs.getString(2)%>(<%=rs.getString(3)%>)</td>

<% if(i==1){%>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;">0.00</td>
<% } else { %>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=rs.getString(5)%></td>
<%} %>

49
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=rs.getString(6)%></td>
<td style="border:1px solid red; align:left; margin-left:5px; margin-right:5px;
padding:5px;"><%=rs.getString(8)%></td>
</tr>
<%} %>

</table>
<br/>
<form action="index.jsp" method="post">
<input type="submit" value="Return" style="width:170px;height:40px;color:white;background-
color:red;border-radius:5px;font-family:max-height;font-size:15px;" href="index.jsp">
</form>
</div>
</div>
</div>
</div>

</div>
</center>
</body>
</html>

50
CHAPTER : 5

51
5. Advantages

 At present user has to go to metro stations for tickets query.

 There is difficulty in accessing data and it is time consuming.

 People don’t have much free time.

 User has to visit enquiry counters which is time taking.

 We provide all types of information’s related metro, in this website.

 All user has to do is open the website and fetch his query.

52
5.1 CONCLUSION

The project entitled LUCKNOW METRO RAIL GUIDE was completed successfully.

The system has been developed with much care and free of errors and at the same time it is
efficient and less time consuming. The purpose of this project was to develop a web application
for metro rail guide.

This project helped us in gaining valuable information and practical knowledge on several topics
like designing web pages using html &css, usage of responsive templates, designing of android
applications, and management of database using mysql. The entire system is secured. Also the
project helped us understanding about the development phases of a project and software
development life cycle. We learned how to test different features of a project.

This project has given us great satisfaction in having designed an application which can be
implemented to any nearby shops or branded shops selling various kinds of products by simple
modifications.

There is a scope for further development in our project to a great extend. A number of features
can be added to the system in future like watch me module, each admin having separate
permissions.

53
5.2Future Scope

It is unreasonable to consider a computer based information system complete or finished;

the system continues to evolve throughout its life cycle, even if it’s successful. It is the case with

this system too. Due to the creative nature of the design, there remain some lapse-mistaken

communications between the users and the developers. So, certain aspects of the system must be

modified as operational experience is gained with it. As users work with the system, they

develop ideas for change and enhancements.

Cost effective implementation of the system .the end user is provided with the complete details

of the Metro station found in Lucknow city. Also provides the information about the stations

nearby.

 It has search module for searching the location.

 Evaluating the fare according to the distance travel.

 Provide a simple and easy User Interface.

54
Reference

 For Java installation

 https://www.java.com/en/download/

 For MySql installation

 http://www.mysql.com/index.html

 Reference websites

 www.javatpoint.com

 www.w3schools.com

 http://www.tutorialspoint.com/java/index.htm

 Reference Books

 Thinking in java

 OCJP Certified Programmer for Java

 Learn Java in Easy Steps

 Complete reference Java

55

You might also like