Professional Documents
Culture Documents
Introduction
About Project:
City Guide is an essential whenever we are visiting a particular city. It gives us the
valuable information about the city and saves the time. Our project laid a web based platform
for the city guide and can search every place in the city without taking the help of any
personal guide. You can search a city for its prominent places of the city user, and can get
social and political information of the city, city culture, security, entertainment, Business,
Hotels, and Jobs etc. The main aim of this project services provided to the users who have
registered in the site. The services regarding to city political, historical, conventional places,
bus routes, business companies profile and jobs details.
Our project title is ‘SMART CITY’, a web-based product used to store the details of
particular city and helps all the users who just visits our website. This site also provides all
the services like Hotel booking for tourists, Ticket booking, Transport facility providing,
business related information, marketing details, city news, shopping detail. The website
contains the complete information about particular city like places to be visited, site maps
route maps, Business environment, Job portal, information about organization that transport,
Hospitality and total history of the city. This website can be used by any person who is
having general knowledge about internet. All the users will be first considered as anonymous
user later if he needs any service then he will be treated as registered user.
Overall description consists of background of the entire specific requirement. It also
gives explanation about actor and function which is used. It gives explanation about
architecture diagram and it also gives what we are assumed and dependencies. It also support
specific requirement and also it support functional requirement, supplementary requirement
other than actor which is used. It also gives index and appendices. It also gives explanation
about any doubt and queries. This system can be used as an application for the handicraft
employees and customers of the Handicraft company to manage the product information.
Customer logging should be able to upload the information of the any required product.
Customers/Company representatives logging in may also access/search any information of
product related.
1
2. Project Analysis
2.1 Purpose of the Project:
The main aim of this project services provided to the users who have registered in
the site. The services regarding to city political, historical, conventional places, bus routes,
business companies profile and jobs details. Smart city is a web-based product used to store
the details of particular city and helps all the users who just visit our website. This site also
provides all the services like Hotel booking for tourists, Ticket booking, Transport facility
providing, business related information, marketing details, city news, shopping detail. The
website contains the complete information about particular city like places to be visited, site
maps route maps, Business environment, Job portal, information about organization that
provide transport, Hospitality and total history of the city. This website can be used by any
person who is having general knowledge about internet. All the users will be first considered
as anonymous user later if he needs any service then he will be treated as registered user.
It facilitates communication between users, experts and general public through
chat/polls/mail. This will definitely help the users for the purpose of saving their valuable
time which can’t be got back which is also economically viable. This system provides a
registration form for all who wants to get the services. This can be categorized based on the
type of users. It provides different registration forms for different categories. In case of
students if they need to download any material or to get information about coaching centers
and college institutions/Incase of businessmen to get the information about any kind of
business/Incase of tourists to get the hospitality facilities/in case of jobseekers to get the
information about available job details they need to give their ID&PASSWORD for security
purpose and AC.NO only at the time of transactional providence.
2
2.2 Existing System:
In Existing system the person who are visiting a particular city need to gather
information from the person who is staying in the city or take the help of the guide in the city.
Gather of all these information you need to visit the city. This possess a lot of time and pre-
planning. In order to get each piece of information we need to go for help desk.
The existing system is a manual system. Here the city information needs to save his
information in the form of excel sheets or Disk Drives.
There is no sharing is possible if the data is in the form of paper or Disk drives.
The manual system gives us very less security for saving data; some data may be lost
due to mismanagement.
The Proposed System provides an online information about the particular city going
to visit. It also provides additional services to the registered user. The development of this
new system contains the following activities, which try to automate the entire process
keeping in the view of database integration approach.
The system makes the overall project management much easier and flexible.
The city information files can be stored in centralized database which can be
maintained by the system.
3
3. Requirement Analysis
Scope:
4
4. Specific Requirements
Functional Requirements:
Complete-map of the city with key markets and places to see marked-preferably
usage of static map and live map option.
Start atleast 4 paid services like SMS alerts for city news, market daily rates.
Non-Functional Requirements:
24*7 availability
Better component design to get better performance at peak time
Flexible service based architecture will be highly desirable for future extension.
5
5. System Requirements
HARDWARE REQUIREMENTS:
Pentium 233HZ 80 GB HD, 1024 MB RAM (Server).
Any P.C with Windows, 256 MB RAM (Client).
Internet connection with 33.6 KBPS Modem.
SOFTWARE REQUIREMENTS:
Windows XP
Eclipse
JDBC ODBC 2.0 drivers installed
Database-MySQL DB
J2EE
<header>
<!--Navbar-->
<nav class="navbar navbar-expand-lg navbar-dark fixed-top scrolling-navbar">
<div class="container">
<a class="navbar-brand" href="#">
6
<img class="img-fluid logo" src="assets/images/smart.png"
alt="Smart City">
</a>
<button class="navbar-toggler" type="button" data-toggle="collapse"
data-target="#navbarSupportedContent-7"
aria-controls="navbarSupportedContent-7" aria-expanded="false"
aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarSupportedContent-7">
<ul class="navbar-nav mr-auto">
<li class="nav-item">
<a class="nav-link" href="#">Home</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">City</a>
</li>
</ul>
<form class="form-inline">
<div class="md-form my-0">
<input class="form-control mr-sm-2" type="text"
placeholder="Search" aria-label="Search">
</div>
</form>
</div>
</div>
</nav>
<!-- Navbar -->
<!-- Full Page Intro -->
<div class="view">
<video src="assets/images/backv.mp4" loop muted autoplay></video>
<!-- Mask & flexbox options-->
<div class="mask rgba-gradient align-items-center">
<!-- Content -->
<div class="container">
<!--Grid row-->
<div class="row rows">
<!--Grid column-->
<div class="col-md-5 mb-5 mt-md-0 mt-5 white-text text-center
text-md-left">
<h1 class="h1-responsive font-weight-bold wow fadeInLeft"
data-wow-delay="0.3s">Bangalore
Smart City </h1>
<hr class="hr-light wow fadeInLeft" data-wow-delay="0.3s">
<h6 class="mb-3 wow fadeInLeft" data-wow-
delay="0.3s">Lorem ipsum dolor sit amet,
consectetur adipisicing elit. Rem repellendus quasi
fuga
nesciunt dolorum nulla magnam veniam sapiente, fugiat!
Commodi sequi non animi ea
dolor molestiae, quisquam iste, maiores. Nulla.</h6>
<a class="btn btn-outline-white wow fadeInLeft" data-wow-
delay="0.3s">Learn more</a>
</div>
<!--Grid column-->
<!--Grid column-->
<div class="col-md-7 col-xl-7 mb-4">
<!--Form-->
7
<div class="card card3 wow fadeInRight" data-wow-
delay="0.3s">
<div class="card-body">
<!--Header-->
<div class="login-page">
<div class="form">
<form class="register-form"
action="User_Register">
<h1 class="h1-responsive font-weight-
bold wow fadeInLeft text-white text-center"
data-wow-delay="0.3s">
Register </h1>
<div class="md-form">
<i class="fas fa-user prefix
white-text active"></i>
<input type="text" id="form3"
name="user_name" class="white-text form-control">
<label for="form3"
class="active">Your name</label>
</div>
<div class="md-form">
<i class="fas fa-envelope prefix
white-text active"></i>
<input type="email" id="form2"
name="user_email" class="white-text form-control">
<label for="form2"
class="active">Your email</label>
</div>
<div class="md-form">
<i class="fas fa-mobile prefix
white-text active"></i>
<input type="text" id="form5"
name="user_mobile" class="white-text form-control">
<label for="form5"
class="active">Your Mobile</label>
</div>
<div class="md-form">
8
<div class="md-form">
<i class="far fa-address-book
prefix white-text active"></i>
<textarea id="form7"
name="user_address" class="md-textarea form-control"
rows="3"></textarea>
<label for="form7">Material
textarea</label>
</div>
<div class="md-form">
<i class="fas fa-lock prefix
white-text active"></i>
<input type="password"
name="user_password"id="form4" class="white-text form-control">
<label for="form4">Your
password</label>
</div>
<div class="text-center mt-4">
<button class="btn btn-
indigo">Save</button>
<p class="message h1-responsive
font-weight-bold">Already registered? <a
href="#"
class="text-dark h5-
responsive font-weight-bold">Login</a>
</p>
<hr class="hr-light mb-3 mt-4">
</div>
</form>
<form class="login-form"
action="User_login">
<h1 class="h1-responsive font-weight-
bold wow fadeInLeft text-white text-center"
data-wow-delay="0.3s">
Login
</h1>
<hr class="hr-light wow fadeInLeft"
data-wow-delay="0.3s">
<div class="md-form">
<i class="fas fa-envelope prefix
white-text active"></i>
<input type="email" id="form12"
name="user_email" class="white-text form-control">
<label for="form12"
class="active">Your email</label>
</div>
<div class="md-form">
<i class="fas fa-lock prefix
white-text active"></i>
<input type="password"
id="form13" name="user_password" class="white-text form-control">
<label for="form13">Your
password</label>
</div>
<div class="text-center mt-4">
9
<button class="btn btn-
indigo">Login</button>
<p class="message h1-responsive
font-weight-bold">Not registered? <a
href="#" class="text-dark
h5-responsive font-weight-bold">Create
an
account</a>
</p>
<hr class="hr-light mb-3 mt-4">
<a href="" class="text-dark" data-
toggle="modal"
data-
target="#modalLoginRest">Forgot Password</a>
</div>
</form>
</div>
</div>
</div>
</div>
<!--/.Form-->
</div>
<!--Grid column-->
</div>
<!--Grid row-->
</div>
<!-- Content -->
</div>
<!-- Mask & flexbox options-->
</div>
<!-- Full Page Intro -->
</header>
<!-- Main navigation -->
<!--Main Layout-->
<main>
<div class="container">
<!--Grid row-->
<div class="row py-5">
<!--Grid column-->
<div class="col-md-12 text-center">
<h1>About</h1>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do
eiusmod tempor incididunt ut
labore et dolore magna aliqua. Ut enim ad minim veniam, quis
nostrud exercitation ullamco
laboris nisi ut aliquip ex ea commodo consequat. Duis aute
irure dolor in reprehenderit in
voluptate velit esse cillum dolore eu fugiat nulla pariatur.
Excepteur sint occaecat cupidatat
non proident, sunt in culpa qui officia deserunt mollit anim
id est laborum.</p>
</div>
<!--Grid column-->
</div>
10
<!--Grid row-->
</div>
</main>
<!--Main Layout-->
Register
Register.java
package com.smart;
import java.io.IOException;
import javax.servlet.ServletException;
11
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
/**
*/
@WebServlet("/User_Register")
//m.setUser_id((user_id)+(m.getId()));
12
m.setUser_name(user_name);
m.setUser_email(user_email);
m.setUser_mobile(user_mobile);
m.setUser_dob(user_dob);
m.setUser_gender(user_gender);
m.setUser_address(user_address);
m.setUser_password(user_password);
int x=m.userregister();
if(x==1)
try
response.sendRedirect("/SmartCity/regsuccese.jsp");
catch (Exception e)
else if(x==-1)
try
response.sendRedirect("/SmartCity/alreadyReg.jsp");
catch (Exception e)
13
}
else
try
response.sendRedirect("/SmartCity/regerror.jsp");
catch (Exception e)
Login.java
package com.smart;
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
/**
14
* Servlet implementation class Admin_login
*/
@WebServlet("/Admin_login")
m.setAdmin_email(admin_email);
m.setAdmin_password(admin_password);
boolean x=m.adminlogin();
if(psd.equals(admin_password))
String admin_name=m.getAdmin_name();
session.setAttribute("admin_name", admin_name);
session.setAttribute("admin_email", admin_email);
if(x==true)
try
15
{
response.sendRedirect("/SmartCity/dasboard.jsp");
catch(Exception e)
e.printStackTrace();
else
try
response.sendRedirect("/SmartCity/adminfaillogin.jsp");
catch(Exception e)
e.printStackTrace();
16
Home.jsp
<%@page import="java.sql.DriverManager"%>
<%@page import="java.sql.ResultSet"%>
<%@page import="java.sql.Statement"%>
<%@page import="java.sql.Connection"%>
<%
17
<ul class="navbar-nav mr-auto">
<li class="nav-item">
<a class="nav-link" href="#">Home</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">City</a>
</li>
</ul>
<ul class="navbar-nav ml-auto">
<li class="nav-item">
<a class="nav-link" href="#"><%
out.println(session.getAttribute("user_name"));
%></a>
</li>
<li class="nav-item">
<a class="nav-link" href="User_logout">Logout</a>
</li>
</ul>
</div>
</div>
</nav>
<!-- Navbar -->
</div>
<!--------- intput----->
</form>
</div>
<!------------------colo-s-->
</div>
</div>
<div class="container">
<div class="row" id="myUL">
<%
18
try{
connection = DriverManager.getConnection(connectionUrl+database, userid,
password);
statement=connection.createStatement();
String sql ="select * from category";
resultSet = statement.executeQuery(sql);
while(resultSet.next()){
%>
<div class="col-lg-6 col-md-12 mb-4 li">
<!--Card-->
<a href="#" hidden><%=resultSet.getString("img_name") %></a>
<div class="card city-card city">
<!--Card image-->
<div class="view overlay hm-white-slight city-card">
<img src="post/<%=resultSet.getString("photo") %>"
class="img-fluid card-img-top" alt="photo">
<a href="#!">
<div class="mask"></div>
</a>
</div>
<!--Card content-->
<div class="card-body">
<!--Title-->
</div>
</div>
<!--/.Card-->
</div>
<!--col--->
<%
}
connection.close();
} catch (Exception e) {
e.printStackTrace();
}
%>
</div>
</div>
19
ul = document.getElementById("myUL");
li = ul.getElementsByClassName("li")
//li = ul.getElementsByTagName("li");
for (i = 0; i < li.length; i++) {
a = li[i].getElementsByTagName("a")[0];
txtValue = a.textContent || a.innerText;
if (txtValue.toUpperCase().indexOf(filter) > -1) {
li[i].style.display = "";
} else {
li[i].style.display = "none";
}
}
}
</script>
20
Data base user
21
Admin Side
Admin.java
package com.smart;
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
/**
22
*/
@WebServlet("/Admin_login")
m.setAdmin_email(admin_email);
m.setAdmin_password(admin_password);
boolean x=m.adminlogin();
if(psd.equals(admin_password))
String admin_name=m.getAdmin_name();
session.setAttribute("admin_name", admin_name);
session.setAttribute("admin_email", admin_email);
if(x==true)
try
23
response.sendRedirect("/SmartCity/dasboard.jsp");
catch(Exception e)
e.printStackTrace();
else
try
response.sendRedirect("/SmartCity/adminfaillogin.jsp");
catch(Exception e)
e.printStackTrace();
24
package com.smart;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import javax.servlet.ServletException;
import javax.servlet.annotation.MultipartConfig;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.Part;
/**
*/
@MultipartConfig
25
@WebServlet("/Category")
//doGet(request, response);
String uploadPath="F:/servlet/SmartCity/src/main/webapp/post/"+photo;//uoload
path where we have to upload our actual image
//m.setUser_id((user_id)+(m.getId()));
m.setImg_name(img_name);
m.setLocation(location);
m.setDescription(description);
m.setPhoto(photo);
26
int x=m.post();
try
InputStream is = file.getInputStream();
is.read(data);
fos.write(data);
fos.close();
catch(Exception e)
e.printStackTrace();
if(x==1)
try
response.sendRedirect("/SmartCity/succeseCatgory.jsp");
catch (Exception e)
27
}
else
try
response.sendRedirect("/SmartCity/errorCategory.jsp");
catch (Exception e)
List of Category
28
<jsp:include page="header.jsp" />
<!--Navbar-->
<!--Navbar-->
<%@page import="java.sql.DriverManager"%>
<%@page import="java.sql.ResultSet"%>
<%@page import="java.sql.Statement"%>
<%@page import="java.sql.Connection"%>
<%
29
</button>
<div class="collapse navbar-collapse" id="navbarSupportedContent-7">
<ul class="navbar-nav mr-auto">
<li class="nav-item">
<a class="nav-link " href="category.jsp">Add Category</a>
</li>
<li class="nav-item">
<a class="nav-link " href="listpost.jsp">List of Post</a>
</li>
<li class="nav-item">
<a class="nav-link" href="listsubpost.jsp">List of Sub
Post</a>
</li>
</ul>
<ul class="navbar-nav ml-auto">
<li class="nav-item" >
</li>
<li class="nav-item">
<a class="nav-link text-dark"
href="Admin_logout">Logout</a>
</li>
</ul>
</div>
</div>
</nav>
<!-- Navbar -->
<div class="container" style="margin-top: 10%;">
<div class="row">
<div class="col-md-12">
<table class="table" id="datatable">
<thead>
<tr>
<th>Post name</th>
<th>Post Location</th>
<th>Description</th>
<th>Post</th>
<th>Action</th>
</tr>
</thead>
<tbody>
<%
try{
connection = DriverManager.getConnection(connectionUrl+database, userid,
password);
statement=connection.createStatement();
String sql ="select * from category";
resultSet = statement.executeQuery(sql);
while(resultSet.next()){
30
%>
<tr>
<td><%=resultSet.getString("img_name") %></td>
<td><%=resultSet.getString("location") %></td>
<td><%=resultSet.getString("description") %></td>
<td> <img src="post/<
%=resultSet.getString("photo") %>" class=" " alt="photo" style="width:50px;
height:50px;"></td>
<td>
<a class="btn rounded-pill btn-rounded
btn-info mb-3 pl-5 pr-5 " href = "$
{pageContext.request.contextPath}/ItemController?action=EDIT&id=$
{item.id}">Edit</a>
</tr>
<%
}
connection.close();
} catch (Exception e) {
e.printStackTrace();
}
%>
</tbody>
</table>
</div>
</div>
</div>
<jsp:include page="footer.jsp" />
Add Post
31
Addpost.java
package com.smart;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import javax.servlet.ServletException;
import javax.servlet.annotation.MultipartConfig;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.Part;
/**
*/
32
@MultipartConfig
@WebServlet("/AddPost")
//doGet(request, response);
String
uploadPath="F:/servlet/SmartCity/src/main/webapp/post/"+post_photo;//uoload path where we
have to upload our actual image
m.setCategory(category);
m.setPost_name(post_name);
m.setPost_description(post_description);
m.setPost_photo(post_photo);
33
int x=m.addpost();
try
InputStream is = file.getInputStream();
is.read(data);
fos.write(data);
fos.close();
catch(Exception e)
e.printStackTrace();
if(x==1)
try
response.sendRedirect("/SmartCity/postSucces.jsp");
catch (Exception e)
34
}
else
try
response.sendRedirect("/SmartCity/posterror.jsp");
catch (Exception e)
List of Post
35
Add Sub Post
package com.smart;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import javax.servlet.ServletException;
import javax.servlet.annotation.MultipartConfig;
36
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.Part;
/**
*/
@MultipartConfig
@WebServlet("/Sub_Post")
//doGet(request, response);
37
String
uploadPath="F:/servlet/SmartCity/src/main/webapp/images/"+sub_post_photo;//uoload path
where we have to upload our actual image
m.setPost(post);
m.setSub_post_name(sub_post_name);
m.setSub_post_photo(sub_post_photo);
int x=m.subaddpost();
try
InputStream is = file.getInputStream();
is.read(data);
fos.write(data);
fos.close();
catch(Exception e)
e.printStackTrace();
38
if(x==1)
try
response.sendRedirect("/SmartCity/subpostSucces.jsp");
catch (Exception e)
else
try
response.sendRedirect("/SmartCity/subposterror.jsp");
catch (Exception e)
39
}
Modal.java
package com.smart;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.Statement;
Connection con=null;
PreparedStatement pstmt=null;
ResultSet res=null;
Statement st = null;
40
private String admin_name;
return imageid;
this.imageid = imageid;
41
public String getImg_name() {
return img_name;
this.img_name = img_name;
return location;
this.location = location;
return description;
this.description = description;
return photo;
this.photo = photo;
42
return admin_id;
this.admin_id = admin_id;
return admin_name;
this.admin_name = admin_name;
return admin_email;
this.admin_email = admin_email;
return admin_password;
this.admin_password = admin_password;
return post_id;
43
}
this.post_id = post_id;
return category;
this.category = category;
return post_name;
this.post_name = post_name;
return post_description;
this.post_description = post_description;
return post_photo;
this.post_photo = post_photo;
44
}
return sub_post_id;
this.sub_post_id = sub_post_id;
return post;
this.post = post;
return sub_post_name;
this.sub_post_name = sub_post_name;
return sub_post_photo;
this.sub_post_photo = sub_post_photo;
45
/*********************User Login******************/
return user_id;
this.user_id = user_id;
return user_name;
this.user_name = user_name;
46
public String getUser_email() {
return user_email;
this.user_email = user_email;
return user_mobile;
this.user_mobile = user_mobile;
return user_dob;
this.user_dob = user_dob;
return user_gender;
this.user_gender = user_gender;
return user_address;
47
public void setUser_address(String user_address) {
this.user_address = user_address;
return user_password;
this.user_password = user_password;
String url="jdbc:mysql://localhost/smartCity?useSSL=false&serverTimezone=UTC";
String unn="root";
String pwd="";
Modal()
try
DriverManager.registerDriver(new com.mysql.jdbc.Driver());
con=DriverManager.getConnection(url,unn,pwd);
catch(Exception e )
e.printStackTrace();
48
int userregister()
try {
pstmt = con.prepareStatement(ss);
pstmt.setString(1, user_email);
res = pstmt.executeQuery();
if(res.next()==false)
pstmt=con.prepareStatement(s);
pstmt.setInt(1, user_id);
pstmt.setString(2, user_name);
pstmt.setString(3, user_email);
pstmt.setString(4, user_mobile);
pstmt.setString(5, user_dob);
pstmt.setString(6, user_gender);
pstmt.setString(7, user_address);
pstmt.setString(8, user_password);
int x=pstmt.executeUpdate();
return x;
else
return -1;
49
}
catch (Exception e) {
e.printStackTrace();
return 0;
//*********************************Login Module*************
boolean userlogin()
try
pstmt=con.prepareStatement(s);
pstmt.setString(1, user_email);
pstmt.setString(2, user_password);
res=pstmt.executeQuery();
while(res.next()==true)
user_email=res.getString(3);
user_password=res.getString(8);
user_name=res.getString(2);
return true;
50
}
catch(Exception e)
return false;
/************************End userModal*******************/
//*********************************Admin Module*************
boolean adminlogin()
try
pstmt=con.prepareStatement(s);
pstmt.setString(1, admin_email);
pstmt.setString(2, admin_password);
res=pstmt.executeQuery();
while(res.next()==true)
admin_email=res.getString(3);
admin_password=res.getString(4);
admin_name=res.getString(2);
51
return true;
catch(Exception e)
return false;
int post()
try
pstmt=con.prepareStatement(s);
pstmt.setInt(1, imageid);
pstmt.setString(2, img_name);
pstmt.setString(3, location);
pstmt.setString(4, description);
pstmt.setString(5, photo);
int x=pstmt.executeUpdate();
return x;
52
catch (Exception e)
e.printStackTrace();
return 0;
int addpost()
try
pstmt=con.prepareStatement(s);
pstmt.setInt(1, post_id);
pstmt.setString(2, category);
pstmt.setString(3, post_name);
pstmt.setString(4, post_description);
pstmt.setString(5, post_photo);
int x=pstmt.executeUpdate();
return x;
catch (Exception e)
e.printStackTrace();
53
return 0;
int subaddpost()
try
pstmt=con.prepareStatement(s);
pstmt.setInt(1, sub_post_id);
pstmt.setString(2, post);
pstmt.setString(3, sub_post_name);
pstmt.setString(4, sub_post_photo);
int x=pstmt.executeUpdate();
return x;
catch (Exception e)
e.printStackTrace();
return 0;
54
Database
Admin
Category Database
Post Database
55
Sub Post Database
Description:
Description:
Every user can directly access the website and visualize all the Information in the site.
Pre-Condition: No pre condition exists
Flow of events:
Description:
Every user can directly access the website and see all information in the reports.
56
Post condition: Reports Page will be displayed.
Flow of events:
Description:
Every user can directly access the website and visualize all the services only after
registration.
Pre-Condition: First register and Login with user_id and click services button
Flow of events:
57
1: Inval id()
:Login
2: View Social
3: View Political
5: view Places
Places
9: Hotels
7: Vi ew Hotels
12:
6: View Logout
Bus routes
:Hotels
:Bus
:Logout Routes
11: Logout()
5: Display Courses
7: Display Institutes
Data Window
Base
3: Request
58
3: Acknowledgement()
Data
Admin Hotel
Base
Management
2: Update() 1: Send Updates()
5: Update() 9: Acknowledgement()
8: Update()
4: Send Updates()
7: Send Updates()
6: Acknowledgement()
Colleges &
Institutes
Compani
es
1: Login
2: Request for site details 3: forwards to Admin
Business Window Admin
person
4: Send Reply
59
:Login :History :City Particulars Places :Hotels :Bus Routes :Logout
1: Invalid()
2: View Social
3: View Political
4: View News,tvChannels
5: view Places
6: View Busroutes
7: View Hotels
8: View Emergency
9: Hotels
10: View Bus
11: Logout()
12: Logout
Login
Send Reply
60
DataBase Admin Hotel Companies Colleges &
Management Institutes
Send Updates()
Update()
Acknowledgement()
Send Updates()
Update()
Acknowledgement()
Send Updates()
Update()
Acknowledgement()
61
Student Window DataBase Institutes
Login
Display Courses
Select Course
Display Institutes
Select Institutes
Request Fee
Pay fee
Acknowledgemant
6.2.5 Activity Diagram: Activity diagram describes various activities that takes places given
in a particular process. The administrator activity diagram describes how the admin
performs various activities in order to provide various services to the different types of
users.The user activity diagram how the user will interact with the system and also various
services that are accessible by him.
62
6.3 System Specific Module
There are five modules in our project .They are listed below with their description.
1. Administrator Module
2. Tourist Module
3. Student Module
4. Businessman Module
5. Jobseeker module
1.Administrator Module: The admin module is the major module as it is responsible for
carrying out the major operations regarding site updates,business updates ,job alerts etc., It
maintains information regarding other four modules.The various software components in
administrator module update alerts, update industries, update hotels, view resumes,update
,site information. The details regarding complete history such as political and social is
entered by admin and he want he can edit the details once entered.The details regarding
business details such as top companies in the city and its information are entered and he want
he can edit the details once entered.The details regarding job details such as job title,
vacancies and companies profile is entered by admin and he can edit the details once entered.
The details regarding regarding emergency such as phone numbers of with respect to
emergency is entered by admin and he can edit the details one he entered.The details
regarding regarding conventional places such as description an,location,address and image of
the place entered by him and he can edit the details once entered
The details regarding news papers, city channels such which papers are available in the city
entered by admin and he can edit the details once he entered.The details regarding political
leaders entered by admin and he can edit the details once he entered.
2. Tourist Module : Tourist module is maintaining the information regarding the city tourist
spot, hotels in the city entertainment in this city etc..,the user after registration as a tourist is
considered as authorized user. The various software components in the tourist module are
view theaters,vie hotels,view citymap,view ATM locations,view hospitals,view city
history,view travel agency,view bus routes.
3.Jobseeker Module : Jobseeker module is the commercial module as it need some paid
services. The Jobseeker views the jobs portal and find a job availability. He then post his
resume to administrator. The various software components available in the jobseeker module
63
are view jobs, view city information, view institutes, view cityupdates,post resume,view
alerts,view city location.
5. Student Module: The student module maintains the various information regarding various
institutes in the city. The various components in software are view library, view books, view
institutes, view engineering colleges, view coaching centers, view journals.
The list of the software components involved in our project are explained below.
a)ViewMap: It displays the city map of the particular city by redirecting to google map and
thus achieve to give the dynamic map.
b)InsertAlerts: Insert alerts into the database .This is used to give time to time alersts to the
user.
c)viewProfile: It display the information regarding different users who have registered.
d)busearch: It provides the information regarding bus and timings if you give the source
and destination.
g)viewIndustries: It provides information regarding their location and address with some
more description attributes.
j)viewCityguide:It provide the city historical information with the static city map locating
key places in the city.
64
k)add emergency: insert emergency reports into the data base. It provides emergency
services that is needed by the user.
l)Insert Industry: it adds the information of industries in the database which provides the
business person to see the number of industries in the city along with their description.
o)viewresume: The admin will view the resume posted by the user or jobseeker and forward
to an organization.
p)flight Search: it provides the information regarding flights the arrival and departure times.
q)viewIndustries:It provides information regarding their location and address with some
more description attributes.
t)viewCityguide:It provide the city historical information with the static city map locating
key places in the city.
u)add emergency: insert emergency reports into the data base. It provides emergency
services that is needed by the user.
v)Insert Industry: it adds the information of industries in the database which provides the
business person to see the number of industries in the city along with their description.
x)ViewMap: It displays the city map of the particular city by redirecting to google map and
thus achieve to give the dynamic map.
y)InsertAlerts: Insert alerts into the database .This is used to give time to time alersts to the
user.
65
Data Base Tables : The database tables available in our project implementation are
listed below.
Snapshots
6.5 Test Cases
66
Sriram has Student If went to Valid
registered as Home page student
student must be home
didplayed pagess
Testcase:4 Program:Registration.jsp
67
A random If correct If it generate Valid
number is number is another one
generated to entered
fill in form
Testcase:5 Program:addAlert.jsp
68
6.6 Appendix A - Hardware and Software Configurations
HARDWARE REQUIREMENTS:
Pentium 233HZ 80 GB HD, 1024 MB RAM (Server).
Any P.C with Windows, 256 MB RAM (Client).
Internet connection with 33.6 KBPS Modem.
SOFTWARE REQUIREMENTS:
Windows XP
Eclipse
JDK 1.5,web server running on any platform
JDBC ODBC 2.0 drivers installed
Database-Oracle10G
J2EE,AJAX,XML
69
6.8. Appendix C-Limitations and Enhancements
Limitations:
The following books and manuals provided a lot of help to us in making this project a
reality.
The complete Reference Java2 By Patrick Naughton and Herbert Schildt, TMH
Publishing Company Ltd.
Java How To Program By H.M.Dietel and P.J.Dietel,Pearson Education/PHI
Data Base Management Systems,Raghurama Krishnan, Johannes Gerhrke,TATA
McGraw-Hill
Software Engineering By Roger S.Pressman,McGraw Hill International Edition
Pressman
70