You are on page 1of 59

ONLINE ACCOMODATION

Mini Project Report

On

Online Accommodation

Submitted By:
ROHIT JHA
ABHISHEK ANAND
SOUMYA SHRIVASTAVA

In partial fulfillment for the award of the degree of

B. TECH DEGREE

In

COMPUTER SCIENCE & ENGINEERING


SCHOOL OF ENGINEERING
COCHIN UNIVERSITY OF SCIENCE & TECHNOLOGY
KOCHI-682022
MARCH 2014

Division of Computer Science Engineering


Page 1
ONLINE ACCOMODATION

Division of Computer Science

School of Engineering
Cochin University of Science & Technology
Kochi-682022

CERTIFICATE

Certified that this is a bonafide record of the project work titled

ONLINE ACCOMADATION

Done by
ROHIT JHA
ABHISHEK ANAND
SOUMYA SHRIVASTAVA

of VI semester Computer Science & Engineering in the year 2014 in


partial fulfillment of the requirements for the award of Degree of Bachelor
of Technology in Computer Science & Engineering of Cochin University
of Science & Technology.

Dr. SUDHEEP ELAYIDOM M PRAMOD PAVITHRAN


Project Guide Head of Division

Division of Computer Science Engineering


Page 2
ONLINE ACCOMODATION

ACKNOWLEDGEMENT

We take this occasion to thank God, almighty for blessing us with his grace and taking our endeavor to

a successful culmination. We extend our sincere and heartfelt thanks to our esteemed guide

Dr.SUDHEEP ELAYIDOM , for providing us with the right guidance and advice at the crucial junctures

and for showing me the right way. We also take this opportunity to express a deep sense of gratitude to

our class coordinators, Dr. SUDHEEP ELAYIDOM and Mrs PREETHA S for their cordial support,

valuable suggestions and guidance. We extend our sincere thanks to our respected Head of the

division Mr. PRAMOD PAVITHRAN, for allowing us to use the facilities available. We would like to

thank the other faculty members also, at this occasion. Last but not the least, we would like to thank our

friends and family for the support and encouragement they have given us during the course of our work .

Division of Computer Science Engineering


Page 3
ONLINE ACCOMODATION

ABSTRACT

GROUP MEMBERS:

Rohit Jha(Roll no.12120075)

Soumya Shrivastava(Roll no.15120081)

Abhishek Anand(Roll no.13120200)

PROJECT GUIDE:

Dr.SUDHEEP ELAYIDOM

DESCRIPTION:

Online accommodation is a web portal for providing details about the rooms available in our campus

.User need to specify their requirement like gender (male, female),room type(single,

double),region(North India, South India)and range(1000,2000 ,3000).The system will match the user

requirement with the

details in the database and after finding the match the required details is given tothe user.

It will also give information about cooks and shops available inside the campus.

The system will have a Admin page from which he can add details about the rooms. This will reduce the

effort required by the new students and existing student in searching room and other useful things.

LANGUAGE USED:

Division of Computer Science Engineering


Page 4
ONLINE ACCOMODATION

FORE END: HTML5, PHP 5

BACK END : PHP 5,MySql

TABLE OF CONTENTS

1. INTRODUCTION
1.1 PROJECT AIMS AND OBJECTIVES
1.2 BACKGROUND OF PROJECT
1.3 OPERATION ENVIRONMENT

2. SYSTEM ANALYSIS
2.1 SOFTWARE REQUIREMENT SPECIFICATION
2.2 EXISTING VS PROPOSED
2.3 SOFTWARE TOOL USED

3. SYSTEM DESIGN
3.1 DATA FLOW DIAGRAM’S
3.2 TABLE DESIGN

4. SYSTEM IMPLEMENTATION
4.1 MODULE DESCRIPTION

5. SYSTEM TESTING

6.CONCLUSION .
APPENDIX

Division of Computer Science Engineering


Page 5
ONLINE ACCOMODATION

CHAPTER 1
INTRODUCTION

This chapter gives an overview about the aim,objectives, background and operation
environment of the system.

1.1 PROJECT AIMS AND OBJECTIVES


The project aims and objectives that will be achieved after completion of this project are discussed in this
subchapter. The aims and objectives are as follows:
 Online accommodation search
 Details of hostels provided on private basis
 Details of shops in the campus
 Details of cooks and food facilities nearby
 Admin control over the website .
 A full fledged database of all the PG and private hostel in the campus.
 A Google map experience that makes your problem more easy.

1.2 BACKGROUND OF PROJECT


To find room for living in the campus has been a difficulty for a long time , both north and south Indian
students have been a long struggle to overcome this in a short period of time
So under the phenomenal guidance of Mr. sudheep you gave us this fantabuluous idea to develop a
portal to easy the years of difficulty the students have ben facing.
This website gives information about the different accommodationavailable in our own University. It also
provides other necessary information from which a new student freshly arriving to this university such as
shops that are in the campus , the availability of cook in the area .the website also show the Google map
location of some important hostels .thus a package that will easy the accommodation problem.

Division of Computer Science Engineering


Page 6
ONLINE ACCOMODATION

1.3 OPERATION ENVIRONMENT

PROCESSOR INTEL CORE PROCESSOR OR ABOVE FOR BETTER


PERFORMANCE

OPERATING WINDOWS VISTA ,WINDOWS7, UBUNTU,


SYSTEM MAC OS

MEMORY 1GB RAM OR MORE

HARD DISK SPACE MINIMUM 5 GB FOR DATABASE USAGE FOR


FUTURE

DATABASE MY SQL

Division of Computer Science Engineering


Page 7
ONLINE ACCOMODATION

CHAPTER 2

SYSTEM ANALYSIS

In this chapter, we will discuss and analyze about the developing process of Online accommodation
System including software requirement specification (SRS) and comparison between existing and
proposed system. The functional and non functional requirements are included in SRS part to provide
complete description and overview of system requirement before the developing process is carried out.
Besides that, existing vs proposed provides a view of how the proposed system will be more efficient
than the existing one.

2.1 SOFTWARE REQUIREMENT SPECIFICATION


2.1.1GENERAL DESCRIPTION

2.1.1.1 PRODUCT DESCRIPTION:


Online Accommodation System is a computerized system which helps user (student) to search
for rooms available inside the university campus. It reduces the work load of students to
personally go to each and every rooms available and match withyour requirements.

2.1.1.2 PROBLEM STATEMENT:


The problem occurred before having computerized system includes:

2.1.1.2.1 Human Effort


When computerized system is not implemented large amount of human effort is required to
personally go to each and every accommodation available in university.
2.1.1.2.2 Time Wastage

Division of Computer Science Engineering


Page 8
ONLINE ACCOMODATION

When a computerized system is not there large amount of time is wasted in going to each and every
location and talking with the land owner.

2.1.1.2.3 Difficult To Search Room


When there is no computerized system there is always a difficulty in searching rooms because large
amount of effort is put in to prepare the database and if online system was not available same hard
work mustbe put in by the room seeker.
2.1.1.2.4Communication Gap
This problem mostly arises with the North Indian students because of their lack of regional
knowledge. They can’t convey their requirement to the house owner and vice versa.

2.1.2 SYSTEM OBJECTIVES


2.1.2.1 Improvement in control and performance
The system is developed to cope up with the current issues and problems of accommodation .The
system can add user, validate user and is also bug free.
2.1.2.2 Save cost
After computerized system is implemented less human force will be required to search for the
desired rooms.
2.1.2.3 Save time
This computerized system saves a lot of time for the users as they need not personally go to each
and every accommodation and match it with their requirement.
2.1.2.4 Add Info
House owners can add their house’s info if they want into this system with due consent from the
admin.

Division of Computer Science Engineering


Page 9
ONLINE ACCOMODATION

2.1.3 SYSTEM REQUIREMENTS

2.1.3.1NON FUNCTIONAL REQUIREMENTS

2.1.3.1.1EFFICIENCY REQUIREMENT
When this online accommodationportal system will be implemented users and house owners can
easily access online accommodation system and searching for accommodation will be very faster .

2.1.3.1.2 RELIABILITY REQUIREMENT


The system should accurately performs accommodation registration, user validation , report
generation and search.

2.1.3.1.3 USABILITY REQUIREMENT


The system is designed for a user friendly environment so that student and house owners can
perform the various tasks easily and in an effective way.

2.1.3.1.4 IMPLEMENTATION REQUIREMNTS


In implementing whole system it uses html in front end with php as server side scripting language
which will be used for database connectivity and the backend ie the database part is developed
using mysql.

2.1.3.1.5 DELIVERY REQUIREMENTS

Division of Computer Science Engineering


Page 10
ONLINE ACCOMODATION

The whole system is expected to be delivered in six months of time with a weekly evaluation by the
project guide.

2.1.3.2FUNCTIONAL REQUIREMENTS

2.1.3.2.1SEARCH ACCOMODATION

This feature used by the user to search for accommodation in the system. They are required to enter fields
regarding their gender,location,range region etc. .The corresponding details will be retrieved from the
database and displayed to the user.The system performs the search from the database and based on the
entered field required information is displayed to the user.
New accommodation can be added by the admin.
This feature can be performing by all users to register new admin .Admin is the moderator of the page
and can modify info about the accommodation.

2.1.3.2.2VERIFY ACCOMODATION

System must be able to verify information,Only single entry must be assigned for each attribute of a

table and it should not allow two same address having same location id.

Division of Computer Science Engineering


Page 11
ONLINE ACCOMODATION

2.1.3.2.3 DESCRIPTION OF COOK

In this feature we can get the info about the cook available in the university along with their
contact information and their in picsSystem must be able to filter cook details based on keyword
entered.System must be able to show the filtered cook in table view

2.1.3.2.4SHOP DETAILS

This feature gives details about the shop stationed in our campus. System must be able to enter

cook information in database.System must be able to update details of cooks.System must be able to

search if cook is available or not before issuingcook.

Division of Computer Science Engineering


Page 12
ONLINE ACCOMODATION

2.1.4 SOFTWARE AND HARDWARE REQUIREMENTS


This section describes the software and hardware requirements of the system
2.1.4.1 SOFTWARE REQUIREMENTS
2.1.4.1.1 Operating system- Windows 7 is used as the operating system as it is stable and supportsmore
features and is more user friendly
2.1.4.1.2 Database MYSQL-MYSQL is used as database as it easy to maintain and retrieve records by simple
queries which are in English language which are easy to understand and easy to write.
2.1.4.1.3 Development tools and Programming language- HTML is used to write the whole code and develop
webpages with CSS, java script for styling work and php for sever side scripting.

2.1.4.2 HARDWARE REQUIREMENTS


nd
Intel core i5 2 generation is used as a processor because it is fast than other processors an provide
reliable and stable and we can run our pc for longtime. By using this processor we can keep on
developing our project without any worries.
Ram 1 GB is used as it will provide fast reading and writing capabilities and will inturn support in
processing

Division of Computer Science Engineering


Page 13
ONLINE ACCOMODATION

2.1.5 EXISTING VS PROPOSED SYSTEM

The process of finding accommodation was relatively very difficult and made it trouble
for students and parents to find room in campus thus to overcome this this portal was
designed:
i. There is no such existing system presently and this made is difficult
ii. The searching process included a lot of hardship and wastage of time.
iii. The proposed system is completely new concept that will be helpful to students and parents
iv. The proposed system makes a great database of all the accommodation of the campus thus
can be used for other purpose too.
v. The proposed system is quiet secure as only admin is allowed make any entry to it

Division of Computer Science Engineering


Page 14
ONLINE ACCOMODATION

2.1.6SOFTWARE TOOLS USED

The whole Project is divided in two parts the front end and the back end.

Front end
The front end is designed using of html , Php ,css, Java script :
1. HTML

HTML- HTML or Hyper Text Markup Language is the main markup language for
creating web pages and other information that can be displayed in a web browser.HTML is
written in the form of HTML elementsconsisting of tags enclosed in angle
brackets (like <html>), within the web page content. HTML tags most commonly come in pairs
like <h1> and </h1>, although some tags represent empty elements and so are unpaired, for
example <img>. The first tag in a pair is the start tag, and the second tag is the end tag (they
are also called opening tags and closing tags). In between these tags web designers can add
text, further tags, comments and other types of text-based content. The purpose of a web
browser is to read HTML documents and compose them into visible or audible web pages. The
browser does not display the HTML tags, but uses the tags to interpret the content of the
page.HTML elements form the building blocks of all websites. HTML allows images and
objects to be embedded and can be used to create interactive forms. It provides a means to
create structured documents by denoting structural semantics for text such as headings,
paragraphs, lists, links, quotes and other items. It can embed scripts written in languages such
as JavaScript which affect the behavior of HTML web pages.

An HTML document has a definite structure that must be specified to the browser. The HTML's
beginning and end must be defined, as well as the document's HEAD (which contains information for
the browser that does not appear in the browser's main window) and its BODY (which contains the text
that will appear in the browser's main window). The use and order of tags that define the HTML
structure are described below.

Division of Computer Science Engineering


Page 15
ONLINE ACCOMODATION

<html> Marks the beginning of your HTML


<head> Begins the heading section of an HTML document
<title> ... </title> Gives an HTML document a title that appears on the browser menu bar,
also will appear on search engines or bookmarks referencing your site
(must appear between the <HEAD> ... </HEAD> tags; should be straight
text, no tags
</head> Defines the end of the heading
<body> Defines the body of an HTML document (text contained within the
<BODY> … </BODY> tags appears in the main browser window). Can be
used with "BGCOLOR", "TEXT", "LINK", and "VLINK" attributes
</html> Defines the end of your HTML document

Links used in HTML

<A HREF="http://some.web.server/Document.html"> ... </A>


Creates a hypertext link to another page.

<A HREF="http://some.web.server/Document.html#AnchorName"> ... </A>


Creates a link to an anchor in another web page.

<A HREF="AnchorName"> ... </A>


Creates an anchor within a document that can be linked to.

<IMG SRC="filename.ext">
Inserts a graphic into the web page. "SRC" is a required attribute. "HEIGHT",
"WIDTH", "ALT", "BORDER" and "ALIGN" are optional attributes.

Division of Computer Science Engineering


Page 16
ONLINE ACCOMODATION

2. Cascading Style Sheets

CSS- Cascading Style Sheets (CSS) is a style sheet language used for describing the look and
formatting of a document written in a markup language. While most often used to style web
pages and interfaces written in HTML and XHTML, the language can be applied to any kind
of XML document, including plain XML, SVG and XUL. HTML was originally designed as a simple
way of presenting information, with the aesthetics of a web page being far less important than the
content (and largely being left up to the web browser). Of course, now that the web has become as
popular as it has, the presentation of your content has become almost critical to a site’s success.
CSS is the key presentational technology that is used to design websites. CSS is a cornerstone
specification of the web and almost all web pages use CSS style sheets to describe their
presentation.CSS is designed primarily to enable the separation of document content from
document presentation, including elements such as the layout, colors, and fonts. This separation
can improve content accessibility, provide more flexibility and control in the specification of
presentation characteristics, enable multiple pages to share formatting, and reduce complexity and
repetition in the structural content (such as by allowing for table less web design).CSS can also
allow the same markup page to be presented in different styles for different rendering methods,
such as on-screen, in print, by voice (when read out by a speech-based browser or screen reader)
and on Braille-based, tactile devices. It can also be used to allow the web page to display differently
depending on the screen size or device on which it is being viewed. While the author of a document
typically links that document to a CSS file, readers can use a different style sheet, perhaps one on
their own computer, to override the one the author has specified. However if the author or the
reader did not link the document to a specific style sheet the default style of the browser will be
applied.CSS specifies a priority scheme to determine which style rules apply if more than one rule
matches against a particular element. In this so-called cascade, priorities or weights are calculated
and assigned to rules, so that the results are predictable.

Division of Computer Science Engineering


Page 17
ONLINE ACCOMODATION

3 JavaScript (JS)

JAVA SCRIPT- JavaScript (JS) is a dynamic computer programming language. It is most commonly
used as part of web browsers, whose implementations allow client-side scripts to interact with the user,
control the browser, communicate asynchronously, and alter the document content that is displayed. It
is also being used in server-side programming, game development and the creation of desktop and
mobile applications. JavaScript is a prototype-based scripting language with dynamic typing and
has first-class functions. Its syntax was influenced by C. JavaScript copies many names and naming
conventions from Java, but the two languages are otherwise unrelated and have very different
semantics. The key design principles within JavaScript are taken from
the Self and Scheme programming languages. It is a multi-paradigm language, supporting object-
oriented, imperative, and functional programming styles. The application of JavaScript to use outside of
web pages—for example, in PDF documents, site-specific browsers, and desktop widgets—is also
significant. Newer and faster JavaScript VMs and platforms built upon them (notably Node.js) have also
increased the popularity of JavaScript for server-side web applications. On the client side, JavaScript
was traditionally implemented as an interpreted language but just-in-time compilation is now performed
by recent (post-2012) browsers.

Division of Computer Science Engineering


Page 18
ONLINE ACCOMODATION

4. PHP

PHP is a server-side scripting language designed for web development but also used as a general-
purpose programming language.PHP is a popular general-purpose scripting language that is especially
suited to web development.Fast, flexible and pragmatic, PHP powers everything from your blog to the
most popular websites in the world. PHP is now installed on more than 244 million websites and 2.1
million web servers. Originally created by Rasmus Lerdorf in 1995, the reference implementationof PHP
is now produced by The PHP Group. While PHP originally stood for Personal Home Page, it now stands
for PHP: Hypertext Preprocessor, a recursive backronym.PHP code is interpreted by a web server with
a PHP processor module, which generates the resulting web page: PHP commands can be embedded
directly into an HTML source document rather than calling an external file to process data. It has also
evolved to include a command-line interface capability and can be used in standalone graphical
applications.PHP is free software released under the PHP License. PHP can be deployed on most web
servers and also as a standalone shell on almost every operating system and platform, free of charge.

4.1 PHP 5

PHP 5 was released in July 2004 after long development and several pre- releases. It is mainly
driven by its core, the Zend Engine 2.0 with a new object model and dozens of other new features.

PHP's development team includes dozens of developers, as well as dozens others working on PHP-
related and supporting projects, such as PEAR, PECL, and documentation, and an underlying network
infrastructure of well over one-hundred individual web servers on six of the seven continents of the

Division of Computer Science Engineering


Page 19
ONLINE ACCOMODATION

world. Though only an estimate based upon statistics from previous years, it is safe to presume PHP is
now installed on tens or even perhaps hundreds of millions of domains around the world.

BACK END- The back end is designed using mysql which is used to design the databases

 MYSQL- MySQL ("My S-Q-L", officially, but also called "My Sequel") is (as of July 2013) the
world's second most widely used open-source relational database management
system (RDBMS). It is named after co-founder Michael Widenius daughter, My. The SQL phrase
stands for Structured Query Language. The MySQL development project has made its source
code available under the terms of the GNU General Public License, as well as under a variety
of proprietary agreements. MySQL was owned and sponsored by a single for-profit firm,
the Swedish company MySQL AB, now owned by Oracle Corporation .MySQL is a popular
choice of database for use in web applications, and is a central component of the widely
used LAMP open source web application software stack (and other 'AMP' stacks). LAMP is an
acronym for "Linux, Apache, MySQL, Perl/PHP/Python." Free-software-open source projects
that require a full-featured database management system often use MySQL. For commercial
use, several paid editions are available, and offer additional functionality. Applications which use
MySQL databases include: TYPO3, MODx, Joomla, WordPress, phpBB, MyBB, Drupal and
other software. MySQL is also used in many high-profile, large-scale websites,
including Wikipedia, Google (though not for searches), Facebook, Twitter, Flickr, and YouTube

2 PHP is a server-side scripting language designed for web development but also used as a general-
purpose programming language.PHP is a popular general-purpose scripting language that is
especially suited to web development.Fast, flexible and pragmatic, PHP powers everything from
your blog to the most popular websites in the world. PHP is now installed on more than 244
million websites and 2.1 million web servers. Originally created by Rasmus Lerdorf in 1995,

Division of Computer Science Engineering


Page 20
ONLINE ACCOMODATION

the reference implementationof PHP is now produced by The PHP Group. While PHP originally
stood for Personal Home Page, it now stands for PHP: Hypertext Preprocessor, a
recursive backronym.PHP code is interpreted by a web server with a PHP processor module, which
generates the resulting web page: PHP commands can be embedded directly into an HTML source
document rather than calling an external file to process data. It has also evolved to include
a command-line interface capability and can be used in standalone graphical applications.PHP
is free software released under the PHP License. PHP can be deployed on most web servers and
also as a standalone shell on almost every operating system and platform, free of charge.

PHP 5

PHP 5 was released in July 2004 after long development and several pre- releases. It is
mainly driven by its core, the Zend Engine 2.0 with a new object model and dozens of
other new features.

PHP's development team includes dozens of developers, as well as dozens others working
on PHP-related and supporting projects, such as PEAR, PECL, and documentation, and an
underlying network infrastructure of well over one-hundred individual web servers on six of
the seven continents of the world. Though only an estimate based upon statistics from
previous years, it is safe to presume PHP is now installed on tens or even perhaps
hundreds of millions of domains around the world.

Division of Computer Science Engineering


Page 21
ONLINE ACCOMODATION

CHAPTER 3
SYSTEM DESIGN

GENERAL MODEL
General model of online accommodation is shown in fig in which administrator and staff at remote
Server can send request to client system to capture their desktop.

STAFF ADMIN STAFF


\

NETWORK

Division of Computer Science Engineering


Page 22
ONLINE ACCOMODATION

CLIENT1 CLIENT2 CLIENT3

Fig:3.1 General model


DFD
The system is divided into various modules ,each module are further divided into sub-module. The
connection of the main modules is shown with the help of DFDs.DFDs are made of the following
representation-
DFD symbols:

Fig:3.2 Process or action

Fig:3.3 Flow of data

Division of Computer Science Engineering


Page 23
ONLINE ACCOMODATION

Fig:3.4 Input or output to the system

Fig:3.4 Storage elements like files,etc.

3.1 DATA FLOW DIAGRAMS

DATA FLOW DIAGRAM FOR SERVICES FORM

SEARCH DATABASE

ENTER
ENTER SPECIF CHECK
STUDENT NAME FOR
D
ICATION
MATCH
IF FOUND

ACCOMADATION
WEB SERVER DISPLAY
PAGE

Division of Computer Science Engineering


Page 24
ONLINE ACCOMODATION

After entering to the home page of the website, student/parent can choose the services option where they are
asked to enter name ,gender, range and location etc. fields that will generate a search result on the basis of match
found retrieving data from search database.

DATA FLOW DIAGRAM FOR ADMIN LOGIN

ADMIN
DATABASE

ENTER
ENTER USERNAME CHECK
ADMINT URL & VALIDITY
PASSWORD

IF VALID

ADMIN
WEB SERVER LOGIN
PAGE

FIGURE :3.1

After entering to the home page of the website, admin can choose the admin LOGIN option where they
are asked to enter username &password, and if he/she is a valid user then a admin login page will be
displayed and will be redirected to a data addition page.

Division of Computer Science Engineering


Page 25
ONLINE ACCOMODATION

DATA FLOW DIAGRAM FOR DATA ENTRY PAGE

O.
ADMIN DATA ENTER
IF
MESSAGE UPDTE
ESSGE
SELECT
LOGIN DETAIL BOOK
NO. “BOK
OF
PAGE ENTRY
ISSUE
VALIDDISPLAYED COPIS RESERVED”
PAGE 3

SEARCH
DATABASE

FIGURE :3.2

Division of Computer Science Engineering


Page 26
ONLINE ACCOMODATION

It is a 2nd level Data Flow Diagram where after entering ADMIN LOGIN page he/she can enter the

required fields related to any accommodation in the campus thus making a control over duplicate and

illegal entry.

TABLE DESIGN

VARIOUS TABELS TO MAINTAIN


INFORMATION
 Search table is used to maintain accommodation details

Field Data type Default Key Extra


locid INT(11) Not Null Primary Auto
increment
location VARCHAR(255) Null
region VARCHAR(255) Null
gender VARCHAR(255) Null
Subject VARCHAR(255) Null
INT(10) Null
Range

Division of Computer Science Engineering


Page 27
ONLINE ACCOMODATION

 ADIMN table is used to maintain accommodation details

Field Data type Default Key Extra


locid INT(11) Not Null Primary Auto
increment
location VARCHAR(255) Null
region VARCHAR(255) Null
gender VARCHAR(255) Null
Subject VARCHAR(255) Null
INT(10) Null
range

 ADMIN LOGIN TABLE

Field Data Type Default Key Extra

Loginid INT(11) NOT NULL Foreign References


key Admin

Username VARCHAR(255) NULL

Password VARCHAR(255) NULL

Division of Computer Science Engineering


Page 28
ONLINE ACCOMODATION

CHAPTER 4
SYSTEM IMPLEMENTATION

4.1 MODULE DESCRIPTION

For Online Accommodation System it is divided into the following Modules:

4.1.1 Admin Module

ADMIN

DATA ENTRY DATA SEARCH REPORT


Division of Computer Science Engineering
VALIDATION GENERATION
Page 29
ONLINE ACCOMODATION

The following module contains various facilities like data entry, data validation ,search and
report generation.

4.1.1 Code for Admin module

4.1.1.1 Code for entering admin username and password


<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-
8" />
<title>Welcome Cusat Accomadation just for you</title>
<meta name="keywords" content="" />
<meta name="" content="" />
<link href="default.css" rel="stylesheet" type="text/css"
media="screen" />
</head>
<body>

<!-- start header -->


<div id="header">
<div id="logo">
<h1><a
href="#"><span><STRONG><bold>ONLINE.....</bold></STRONG
></span> ACCOMODATION</a></h1>
</div>
<div id="menu">
<ul id="main">
<li class="current_page_item"><a
href="index.html">Home</a></li>
<li><a href="form1.html">Services</a></li>
Division of Computer Science Engineering
Page 30
ONLINE ACCOMODATION

<li><a href="adminlogin.html">ADMIN</a></li>
<li><a href="shop.html">Shops</a></li>
<li><a href="cook.html">Cook details</a></li>
<li><a href="gal.html">Gallery</a></li>

</ul>
<ul id="feed">
<li><a href="help.html"><FONT
SIZE=3>HELP</FONT SIZE></a></li>
</ul>
</div>

</div>

<form method="GET" action="logincheck.php">


<p><label for="username"><font size="8">Enter
Username</font></label></p>
<p><input type="text" name="username" value=""></p>

<p><label for="password"><font size="8">Enter


Password</font></label></p>
<p><input type="password" name="password" value=""></p>

<p><font size="8"><input type="submit" name="go"


value="submit"></font></p>
</form>

</body>
</html>

//////////////////////////////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////

Division of Computer Science Engineering


Page 31
ONLINE ACCOMODATION

CODE FOR LOGIN VERIFICATION

<?php #admin/index.php
#####[make sure you put this code before any html
output]#####

//connect to server
$dbc = mysqli_connect("localhost","root","","project") or
die('could not connect: '. mysqli_connect_error());

//select db
mysqli_select_db($dbc, 'project') or die('no db connection');

//check if the login form has been submitted


if(isset($_GET['go'])){
#####form submitted, check data...#####

//step 1a: sanitise and store data into vars (storing


encrypted password)
$usr = $_GET['username'];
$psw = SHA1($_GET['password']) ; //using SHA1() to encrypt
passwords

//step2: create query to check if username and password


match
$q = "SELECT * FROM admin WHERE username='$usr' AND
password='$psw' ";

//step3: run the query and store result


$res = mysqli_query($dbc, $q);

//make sure we have a positive result


if(mysqli_num_rows($res) == 1){
######### LOGGING IN ##########

Division of Computer Science Engineering


Page 32
ONLINE ACCOMODATION

//starting a session
session_start();

//creating a log SESSION VARIABLE that will persist


through pages
$_SESSION['log'] = 'in';

//redirecting to restricted page


header('location:restricted.html');
} else {
//create an error message
$error = 'Wrong details. Please try again';
}
}//end isset go
?>

<html>
<body>
<h1>WRONG PASSWORD
<a href="adminlogin.html">try again </a>
</body>
</html>

//////////////////////////////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////

CODE FOR ENTERING DATA INTO THE DATABASE

<?php

Division of Computer Science Engineering


Page 33
ONLINE ACCOMODATION

$con=mysqli_connect("localhost","root","","project");
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}

$locid1=$_GET['locid'];
$location1=$_GET['location'];
$rangee1=$_GET['rangee'];
$region1=$_GET['region'];
$roomtype1=$_GET['roomtype'];
$ownername1=$_GET['ownername'];
$contact1=$_GET['contact'];
$advance1=$_GET['advance'];
$comment1=$_GET['comment'];
$address1=$_GET['address'];
$sex1=$_GET['sex'];
$landmark1=$_GET['landmark'];

$sql="INSERT INTO search2


(locid,rangee,location,region,roomtype,ownername,address,contac
t,advance,comment,sex,landmark )
VALUES

($locid1,$rangee1,$location1,$region1,$roomtype1,$ownername1,
$address1,$contact1,$advance1,$comment1,$sex1,$landmark1)";
if(!mysqli_query($con,$sql))
{
die(' entered data successfully ');
}
echo "Entered data successfully\n";
mysql_close($con);

?>

Division of Computer Science Engineering


Page 34
ONLINE ACCOMODATION

SERVICES Module

SERVICES

CODE FOR SEARCH


FORM

FORM FILLING THE DATABASE


ADDITION

SEARCH RESET AND

DETAILS LINK TO OTHER

REGARDING The
THE following module contains various facilities like DATA ENTRY IN
MODULE
FORM, SEARCH DATABASE, FORM ADDITION etc.
HOUSE

CODE OF THIS MODULE:


<pre></pre>

Division of Computer Science Engineering


Page 35
ONLINE ACCOMODATION

<div class="form1">
<div style="padding-top:20px">
<h2><b><font color ="black" size="30"><pre>Enter your
requirments and details</pre>
</font></b></h2>
<feildset>
<form method="GET" action="mailing.php">
<table align="center">
<tr>
<td>NAME:
</td>
<td><input type="text" name="name"></td>
</tr>
<tr>
<td>
</td>
</tr>
<tr>
<td>
</td>
</tr>
<tr>
<td>Gender
</td>
<td>
<select name="sex" size="1">
<option selected value="MALE">MALE
</option>
<option value="FEMALE">FEMALE:
</option>
</select>
</td>
</tr>
<tr>
<td>
</td>
</tr><tr>

Division of Computer Science Engineering


Page 36
ONLINE ACCOMODATION

<td>
</td>
</tr>
<tr>
<td>ROOM TYPE:
</td>
<td>
<select name="roomtype" size="1">
<option selected value="SINGLE">single
</option>
<option value="DOUBLE">double
</option>
<option value="ONE_ROOM_FLAT">one room flat
</option>
<option value="DOUBLE_ROOM_FLAT" >Double bed room flat
</option>
</select>
</td>
</tr>
<tr>
<td>
</td>
</tr><tr>
<td>
</td>
</tr>
<tr>
<td>RANGE:
</td>
<td>
<select name="rangee" size="1">
<option selected value="ONE">below 1000
</option>
<option value="TWO" >1000-2000
</option>
<option value="THREE" >beyond 2000
</option>

Division of Computer Science Engineering


Page 37
ONLINE ACCOMODATION

</select>
</td>
</tr>
<br>
<tr>
<td>
</td>
</tr><tr>
<td>
</td>
</tr>
<tr>
<td>LOCATION:
</td>
<td>
<select name="location" size="1">
<option selected value="ABDULLAH">abdullah corner
</option>
<option value="MAVELI">maveli nagar
</option>
<option value="PAYAPILLIY">payapilliy
</option>
<option value="HMT">hmt colony
</option>
<option value="HIDAYAT">hidayat nagar
</option>
</select>
</td>
</tr>
<tr>
<td>
</td>
</tr><tr>
<td>
</td>
</tr>
<tr>

Division of Computer Science Engineering


Page 38
ONLINE ACCOMODATION

<td>Region
</td>
<td>
<select size="1" name="region">
<option selected value="NORTH">North indian
</option>
<option value="SOUTH">South indian
</option>
</select>
</td>
</tr>
<tr>
<td>
<input type="checkbox" value="declaration">

</td>
<td>

<b>
i hereby declare that the above informations are corect
</b>

</tr>
<tr>
<td>
</td>
</tr><tr>
<td>
</td>
</tr><tr>
<td>
</td>
</tr>

<tr>
<td>
<input type="submit" value="SUBMIT">

Division of Computer Science Engineering


Page 39
ONLINE ACCOMODATION

</td>
<td>
<input type="reset" value="RESET">
</td>
</tr>
<tr>
<td>
<div id="capt" class="captcha">
<div style="float:center ;">
<a></a>Please type the code shown in the image: <input
type="text" name="wsp_code"/>
</div>
<div style="float:center;">
<script type="text/javascript"
src="http://webspamprotect.com/captcha/6226/"></script>
<noscript>This form protected by <a
href="http://webspamprotect.com" target="_blank" title="Web form
spam protection">WebSpamProtect</a>.
</noscript>
</div>
</td>
</tr>
</form>
</feildset>
</div>
</body>
</html>

Division of Computer Science Engineering


Page 40
ONLINE ACCOMODATION

3 OTHER MODULE

Some important pages

SHOP SOME
COOK DETAILS
DETAILS RECOMMANDATION
GALLAREY

SECTION
The following module contains various facilities like cook details, shop
details, some special recommendation and gallery.

Division of Computer Science Engineering


Page 41
ONLINE ACCOMODATION

CHAPTER 5
SYSTEM TESTING

The aim of the system testing process was to determine all defects in our project .The program was
subjected to a set of test inputs and various observations were made and based on these observations
it will be decided whether the program behaves as expected or not.
Our Project went through two levels of testing
1.Unit testing
2.Integration testing

Division of Computer Science Engineering


Page 42
ONLINE ACCOMODATION

UNIT TESTING

Unit testing is undertaken when a module has been created and succesfully reviewed .In order to test a
single module we need to provide a complete environment that is besides the module we would
require
4 The procedures belonging to other modules that the module under test calls
5 Non local data structures that module accesses
6 A procedure to call the functions of the module under test with appropriate parameters
Unit testing was done on each and every module that is described under module description of chapter
4
1. Test For the admin module
 Testing admin login form-This form is used for log in of administrator of the system. In this
we enter the username and password if both are correct administration page will open other
wise if any of data is wrong it will get redirected back to the login page and again ask for
username and password

Division of Computer Science Engineering


Page 43
ONLINE ACCOMODATION

2. Test for SERVICES module

In this section the STUDENT/PARENT can get details from main database and the whole
information depending upon the user specification is generated as a table.

INTEGRATION TESTING

In this type of testing we test various integration of the project module by providing the
input .The primary objective is to test the module interfaces in order to ensure that no
errors are occurring when one module invokes the other module.

Division of Computer Science Engineering


Page 44
ONLINE ACCOMODATION

CONCLUSION

This website provides a web portal that is a online accommodation system which will benefit the
students as well as the parents.
It makes entire process online where student and parents can search room online just by few clicks. It
also has a facility for admin login where admin can login and can see status of flats and room issued as
well change there status or give some suggestions. It has a facility of services form where anyone can
search for their accommodation and also a suggestion page is there wherenecessarysuggestion to the
portal can be made and a mesmerizing collection of pictures so that the overview of the campus can be
collected.

Overall this website will help the students as well Parents and will make management of the
accommodation very easy very easy.

THANK YOU

Division of Computer Science Engineering


Page 45
ONLINE ACCOMODATION

APPENDIX:

TIMELINE OF PROJECT
JANUARY

2014

Division of Computer Science Engineering


Page 46
ONLINE ACCOMODATION

Sunday Monday Tues Wedne Thursday Friday Saturda


day sday y
ABSTRA
CT OF
PROJECT
ANALYSIZE
D
SRS OF
THE POJECT
DESIGNED

1 2 3 4 5 6 7
FRONT THE THE
END BASIC MAIN REQUIRED
DEVELOPMEN PAGE IMAGES
T DEVELOPED DETAILS
STRATED COLLECT
8 9 10 11 12 13 14
DEVELOP MAIN MAINPA
MENT OF PAGE GE WORK
LOGO SILDE COMPLET
SHOW OF D
IMAGE
ADDED

15 16 17 18 19 20 21

Division of Computer Science Engineering


Page 47
ONLINE ACCOMODATION

MEETI
NG WITH
GUIDE
22 23 24 25 26 27
SERVICES DATAB SERVICE FIRST
FORM ASE S FORM TABLE
CREATED WORK COMPLETE CREATED
BEGINS D

28 29 30 31

MONTH ENDS

FEBURARY
2014

Division of Computer Science Engineering


Page 48
ONLINE ACCOMODATION

Sunda Monday Tuesd Wedne Thursday Friday Saturday


y ay sday

COLLECTI REVI SEVICES


ON FOR EW FROM
DATBASE FROM COMPLETE
ENTRY BEGIN GUIDE
1 2 3 4 5 6 7
COOK SUDHEEP SUDHEE
PAGE SIR HELPED IN PSIR GAVE
COMPLETED DEVELOPING US
GALLERY PAGE GUIDELINE
TO
DEVELOP
MAILING
PAGE
8 9 10 11 12 13 14
DEVELOP GALLE SMTP SEVER MAILING
MENT OF RY PAGE AND OTHER PAGE
LOGO SILDE INFORMATION WORK
SHOW OF COLLECTED COMPLETD
IMAGE
ADDED

Division of Computer Science Engineering


Page 49
ONLINE ACCOMODATION

15 16 17 18 19 20 21
DEMONST MEETI SUDHEEPSI INFORMA
RATION TO NG WITH R GAVE US TION OF
PREETHA GUIDE GUIDELINE TO HOUSES
MAM ADD SHOP FEED IN
PAGES DATABASE
22 23 GALL 25 26 27 28
ERY
PAGE
COMPLE
TED24
SHOP REVIE ALL
PAGE W FROM REQUIRED
COMPLETED GUIDE TABLES
CREATED

MONTH ENDS

MARCH
2014

Division of Computer Science Engineering


Page 50
ONLINE ACCOMODATION

Sunda Monday Tuesd Wedne Thursday Friday Saturday


y ay sday

1 2 3 4 5 6 7
FINAL ALL THE SUDHEE
ADJUSMENT LINKS ADDED PSIR
BEGIN TO CORRECT REVIEWE
PLACE D AND
CORRECTE
D OUR PHP
SCRIPTS
8 9 10 11 12 13 14
HELP ALL PROJECT
PAGE THE REVIEWED
CREATED IMPORTA
NT
CHANGES
IN OUR
CSS AS
PER
GUDING
OF
SUDHEEP

Division of Computer Science Engineering


Page 51
ONLINE ACCOMODATION

SIR

15 16 17 18 19 20 21
MEETI REPO
NG WITH RT
GUIDE PREPARE
D
22 23 25 26 27 28
ABLE REVIE
TO W FROM FINAL
COMPLET GUIDE PREENTATIO
E THE N
PROJECT
COMPLET
ED

Division of Computer Science Engineering


Page 52
ONLINE ACCOMODATION

SCREENSHOTS

Division of Computer Science Engineering


Page 53
ONLINE ACCOMODATION

FIG:6.1
The above two pictures are the main page that consist the link to various other
pages and modules , it has basic quality to attract and appeal the user

FIGURE:6.2

Division of Computer Science Engineering


Page 54
ONLINE ACCOMODATION

The above screen shot depicts the services page where the user can search
for a new accommodation and is the main tool of this portal is the

FIGURE :6.3
The admin login module for admin to make a login to insert data in the data base

Division of Computer Science Engineering


Page 55
ONLINE ACCOMODATION

FIGURE:6.3
The details of cook are displayed here.

Division of Computer Science Engineering


Page 56
ONLINE ACCOMODATION

Figure:6.4
The vivid images of campus are displayed here.

Division of Computer Science Engineering


Page 57
ONLINE ACCOMODATION

Figure:6.5
The help page is for the convenience of user

Division of Computer Science Engineering


Page 58
ONLINE ACCOMODATION

Figure:6.6
The details of flat are displayed here.

Figure:6.7
This module represent more details of flats.

Division of Computer Science Engineering


Page 59

You might also like