Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Case Diagram ... 11 Class Diagram ..13 ER Diagram ..14 Database Design ... 17

Download as pdf or txt
Download as pdf or txt
You are on page 1of 81

ONLINE COURSE REGISTRATION

CONTENTS

1. Introduction…………………………….1

2. Requirement Specification……………..3

3. Analysis and Design…………………... 7


 Case Diagram…………………...11
 Class Diagram…………………..13
 ER Diagram……………………..14
 Database Design………………...17

4. Implementation……………………….. 20

5. Testing………………………………… 60

6. Screen Shots………………………….. 63

7. System Security………………………..73

8. Conclusion……………………………. 77

9. Bibliography…………………………...79

0
ONLINE COURSE REGISTRATION

1. INTRODUCTION

1
ONLINE COURSE REGISTRATION

Introduction:-
Online Course Registration System is Web-based registration software that helps
you to register courses online. It is ideal for schools, educational camps, corporate
training programs, and online training programs. It also provides time to time
current status information related to courses. It can help for the student need to
register by giving necessary details, for the desired course.

In Online Course Registration we use PHP and MYSQL database. It is web-based


registration software that helps you to register courses online. It is ideal schools,
educational camps, and corporate training program. It has two modules i.e. Admin
and Student.

Admin:
Admin will register the student and provide username; password and pin code. Pin
code will be used when a student enrolls for the course. Admin can manage
session, semester, departments, course, students, students log Admin Panel. Admin
can also add/ delete latest news and updates related to students.

Student:
Student can log in with valid reg no and password provided by admin. Student can
enroll for any course and can printout of the registered course.

Purpose:-
The purpose of project is to build an application program to reduce manual work
for managing the course through internet. This application has good appearance
and easy to operate. It is very simple and easy to access. This project provides lots
of features to manage in very well manner. This project contains advance modules
which make the backend system very powerful.

Scope:-
Online Course Registration project is developed as a web application and it will
work over web.

2
ONLINE COURSE REGISTRATION

2. REQUIREMENT SPECTIFICATION

3
ONLINE COURSE REGISTRATION

Hardware Configuration :

Client Side:

AMfgdfRA RAM 512 MB

Hard disk 10 GB

Processor 1.0 GHz

Server side:

RAM 1 GB

Hard disk 20 GB

Processor 2.0 GHz

Software Requirement:

Client Side:

Google Chrome or any compatible


Web Browser browser
Operating System
Windows or any equivalent OS

4
ONLINE COURSE REGISTRATION

Server Side:

Web Server APACHE

Server side Language PHP5.6 or above version

Database Server MYSQL

Google Chrome or any compatible


Web Browser browser

Operating System Windows or any equivalent OS

APACHE

The Apache HTTP Server Project is an effort to develop and maintain an open-
source HTTP server for modern operating systems including UNIX and Windows.
The goal of this project is to provide a secure, efficient and extensible server that
provides HTTP services in sync with the current HTTP standards.
The Apache HTTP Server ("http") was launched in 1995 and it has been the most
popular web server on the Internet since April 1996. It has celebrated its 20th
birthday as a project in February 2015.

5
ONLINE COURSE REGISTRATION

PHP

• PHP stands for PHP: Hypertext Preprocessor.

• PHP is a server-side scripting language, like


ASP.
• PHP scripts are executed on the server.
• PHP supports many databases (MYSQL, Informix, Oracle, Sybase,
Solid, Generic ODBC, etc.).

• PHP is an open-source software.

• PHP is free to download and use.

MYSQL

• MYSQL is a database server


• MYSQL is ideal for both small and large
applications
• MYSQL supports standard SQL
• MYSQL compiles on a number of platforms

• MYSQL is free to download and use

• How to access MYSQL:

http://localhost/phpmyadmin

6
ONLINE COURSE REGISTRATION

3. ANALYSIS AND DESIGN

7
ONLINE COURSE REGISTRATION

Analysis:

In present all student registration work done on the paper. The whole year student

enroll data is stored in the registers.

Disadvantage of present system:

• Not user friendly: The present system not user friendly because data is not

stored in structure and proper format.

• Manual Control: All report calculation is done manually so there is a

chance of error.

• Lots of paper work: Visitors maintain in the register so lots of paper

require storing details.

• Time consuming

Design Introduction:

Design is the first step in the development phase for any techniques and principles
for the purpose of defining a device, a process or system in sufficient detail to
permit its physical realization.

Once the software requirements have been analyzed and specified the software
design involves three technical activities - design, coding, implementation and
testing that are required to build and verify the software.

8
ONLINE COURSE REGISTRATION

The design activities are of main importance in this phase, because in this activity,
decisions ultimately affecting the success of the software implementation and its
ease of maintenance are made. These decisions have the final bearing upon
reliability and maintainability of the system. Design is the only way to accurately
translate the customer’s requirements into finished software or a system.

Design is the place where quality is fostered in development. Software design is a


process through which requirements are translated into a representation of
software. Software design is conducted in two steps. Preliminary design is
concerned with the transformation of requirements into data

UML Diagrams:
Actor:
A coherent set of roles that users of use cases play when interacting with the
use `cases.

Use case:

A description of sequence of actions, including variants, that a system performs


that yields an observable result of value of an actor.

9
ONLINE COURSE REGISTRATION

UML stands for Unified Modeling Language. UML is a language for specifying,
visualizing and documenting the system. This is the step while developing any
product after analysis. The goal from this is to produce a model of the entities
involved in the project which later need to be built. The representation of the
entities that are to be used in the product being developed need to be designed.

USECASE DIAGRAMS:

Use case diagrams model behavior within a system and helps the developers
understand of what the user require. The stick man represents what’s called an
actor.

Use case diagram can be useful for getting an overall view of the system and
clarifying who can do and more importantly what they can’t do.

Use case diagram consists of use cases and actors and shows the interaction
between the use case and actors.

• The purpose is to show the interactions between the use case and actor.
• To represent the system requirements from user’s perspective.
• An actor could be the end-user of the system or an external system.

USECASE DIAGRAM: A Use case is a description of set of sequence of actions.


Graphically it is rendered as an ellipse with solid line including only its name. Use
case diagram is a behavioral diagram that shows a set of use cases and actors and
their relationship. It is an association between the use cases and actors. An actor
represents a real-world object. Primary Actor – Sender, Secondary Actor
Receiver.

10
ONLINE COURSE REGISTRATION

Use Case Diagrams:

Admin
Session

Semester

Department

Course

Registration

Manage
Student

Enrol History

Student Logs

Manage News

Change
Password

11
ONLINE COURSE REGISTRATION

Student View News / Updates

Sign In

Enrol for Course

Enrol History

Profile

Change Password

12
ONLINE COURSE REGISTRATION

Class Diagram:
A description of set of objects that share the same attributes operations,
relationships, and semantics

13
ONLINE COURSE REGISTRATION

ER Diagram:

The Entity-Relationship (ER) model was originally proposed by Peter in 1976


[Chen76] as a way to unify the network and relational database views. Simply
stated the ER model is a conceptual data model that views the real world as entities
and relationships. A basic component of the model is the Entity-Relationship
diagram which is used to visually represent data objects. Since Chen wrote his
paper the model has been extended and today it is commonly used for database
design for the database designer, the utility of the ER model is:

• It maps well to the relational model. The constructs used in the ER model
can easily be transformed into relational tables.
• It is simple and easy to understand with a minimum of training. Therefore,
the model can be used by the database designer to communicate the design
to the end user.
• In addition, the model can be used as a design plan by the database
developer to implement a data model in specific database management
software.

ER Notation

There is no standard for representing data objects in ER diagrams. Each modeling


methodology uses its own notation. The original notation used by Chen is widely
used in academics texts and journals but rarely seen in either CASE tools or
publications by non-academics. Today, there are a number of notations used;
among the more common are Bachman, crow's foot, and IDEFIX.

All notational styles represent entities as rectangular boxes and relationships as


lines connecting boxes. Each style uses a special set of symbols to represent the

14
ONLINE COURSE REGISTRATION

cardinality of a connection. The notation used in this document is from Martin. The
symbols used for the basic ER constructs are:

• Entities are represented by labeled rectangles. The label is the name of the

entity. Entity names should be singular nouns.

• Relationships are represented by a solid line connecting two entities. The

name of the relationship is written above the line. Relationship names should

be verbs

• Attributes, when included, are listed inside the entity rectangle. Attributes

which are identifiers are underlined. Attribute names should be singular

nouns.

• Cardinality of many is represented by a line ending in a crow's foot. If the

crow's foot is omitted, the cardinality is one.

Existence is represented by placing a circle or a perpendicular bar on the line.


Mandatory existence is shown by the bar (looks like a 1) next to the entity for an
instance is required. Optional existence is shown by placing a circle next to the
entity that is optional.

15
ONLINE COURSE REGISTRATION

16
ONLINE COURSE REGISTRATION

MYSQL Data Tables:


Admin Table: Table Name(admin)
This store admin personal and login details.

Course Table: Table Name(course)


This store the course details

Enrolls Table: Table Name(course enrolls)


This store detail of course enroll

17
ONLINE COURSE REGISTRATION

Department Table: Table Name (department)


This stored department detail

Level Table: Table Name (level)


This stored detail of course level

Semester Table: Table Name (semester)


This store detail of semester

Session Table: Table Name (session)


This stored detail of session

18
ONLINE COURSE REGISTRATION

Student Table: Table Name (student)


This stored detail of student

News: Table Name (news)


This stored the latest news / updates

User logs: Table Name (user log)


This stored detail of user login time

19
ONLINE COURSE REGISTRATION

4. IMPLEMENTATION

20
ONLINE COURSE REGISTRATION

SOURCE CODE
Admin:- Session

<? php
session_start();
include('includes/config.php');
if(strlen($_SESSION['alogin'])==0)
{
header('location:index.php');
}
else{

// Code for Insertion


if(isset($_POST['submit']))
{
$sesssion=$_POST['sesssion'];
$ret=mysqli_query($con,"insert into session(session) values('$sesssion')");
if($ret)
{
echo '<script>alert("Session Created Successfully !!")</script>';
echo '<script>window.location.href=session.php</script>';
}else{
echo '<script>alert("Error : Session not created")</script>';
echo '<script>window.location.href=session.php</script>';
}
}

// Code for Deletion


if(isset($_GET['del']))
{
mysqli_query($con,"delete from session where id = '".$_GET['id']."'");
echo '<script>alert("Session Deleted")</script>';
echo '<script>window.location.href=session.php</script>';
}
?>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />
<meta name="description" content="" />
<meta name="author" content="" />
<title>Admin | Session</title>
<link href="../assets/css/bootstrap.css" rel="stylesheet" />

21
ONLINE COURSE REGISTRATION

<link href="../assets/css/font-awesome.css" rel="stylesheet" />


<link href="../assets/css/style.css" rel="stylesheet" />
</head>
<body>
<?php include('includes/header.php');?>
<!-- LOGO HEADER END-->
<?php if($_SESSION['alogin']!="")
{
include('includes/menubar.php');
}
?>
<!-- MENU SECTION END-->
<div class="content-wrapper">
<div class="container">
<div class="row">
<div class="col-md-12">
<h1 class="page-head-line">Add session </h1>
</div>
</div>
<div class="row" >
<div class="col-md-3"></div>
<div class="col-md-6">
<div class="panel panel-default">
<div class="panel-heading">
Session
</div>
<font color="green" align="center"><?php echo htmlentities($_SESSION['msg']);?><?php echo
htmlentities($_SESSION['msg']="");?></font>
<div class="panel-body">
<form name="session" method="post">
<div class="form-group">
<label for="session">Create Session </label>
<input type="text" class="form-control" id="sesssion" name="sesssion" placeholder="Session"
/>
</div>
<button type="submit" name="submit" class="btn btn-default">Submit</button>
</form>
</div>
</div>
</div>
</div>
<font color="red" align="center"><?php echo htmlentities($_SESSION['delmsg']);?><?php echo
htmlentities($_SESSION['delmsg']="");?></font>
<div class="col-md-12">
<!-- Bordered Table -->
<div class="panel panel-default">
<div class="panel-heading">
Manage Session

22
ONLINE COURSE REGISTRATION

</div>
<!-- /.panel-heading -->
<div class="panel-body">
<div class="table-responsive table-bordered">
<table class="table">
<thead>
<tr>
<th>#</th>
<th>Session</th>
<th>Creation Date</th>
<th>Action</th>
</tr>
</thead>
<tbody>
<?php
$sql=mysqli_query($con,"select * from session");
$cnt=1;
while($row=mysqli_fetch_array($sql))
{
?>
<tr>
<td><?php echo $cnt;?></td>
<td><?php echo htmlentities($row['session']);?></td>
<td><?php echo htmlentities($row['creationDate']);?></td>
<td>
<a href="session.php?id=<?php echo $row['id']?>&del=delete" onClick="return confirm('Are
you sure you want to delete?')">
<button class="btn btn-danger">Delete</button>
</a>
</td>
</tr>
<?php
$cnt++;
} ?>
</tbody>
</table>
</div>
</div>
</div>
<!-- End Bordered Table -->
</div>
</div>
</div>
</div>
<!-- CONTENT-WRAPPER SECTION END-->
<?php include('includes/footer.php');?>
<!-- FOOTER SECTION END-->
<!-- JAVASCRIPT AT THE BOTTOM TO REDUCE THE LOADING TIME -->

23
ONLINE COURSE REGISTRATION

<!-- CORE JQUERY SCRIPTS -->


<script src="../assets/js/jquery-1.11.1.js"></script>
<!-- BOOTSTRAP SCRIPTS -->
<script src="../assets/js/bootstrap.js"></script>
</body>
</html>
<?php } ?>

Semester

<?php
session_start();
include('includes/config.php');
if(strlen($_SESSION['alogin'])==0)
{
header('location:index.php');
}
else{
// COde for insertion
if(isset($_POST['submit']))
{
$semester=$_POST['semester'];
$ret=mysqli_query($con,"insert into semester(semester) values('$semester')");
if($ret)
{
echo '<script>alert("Semester Created Successfully !!")</script>';
echo '<script>window.location.href=semester.php</script>';
}else{
echo '<script>alert("Something went wrong. Please try again.")</script>';
echo '<script>window.location.href=semester.php</script>';
}
}
//Code For Deletion
if(isset($_GET['del']))
{
$sid=$_GET['id'];
mysqli_query($con,"delete from semester where id ='$sid'");
echo '<script>alert("Semester Deleted Successfully !!")</script>';
echo '<script>window.location.href=semester.php</script>';
}
?>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />
<meta name="description" content="" />

24
ONLINE COURSE REGISTRATION

<meta name="author" content="" />


<title>Admin | Semester</title>
<link href="../assets/css/bootstrap.css" rel="stylesheet" />
<link href="../assets/css/font-awesome.css" rel="stylesheet" />
<link href="../assets/css/style.css" rel="stylesheet" />
</head>

<body>
<?php include('includes/header.php');?>
<!-- LOGO HEADER END-->
<?php if($_SESSION['alogin']!="")
{
include('includes/menubar.php');
}
?>
<!-- MENU SECTION END-->
<div class="content-wrapper">
<div class="container">
<div class="row">
<div class="col-md-12">
<h1 class="page-head-line">Semester </h1>
</div>
</div>
<div class="row" >
<div class="col-md-3"></div>
<div class="col-md-6">
<div class="panel panel-default">
<div class="panel-heading">
Semester
</div>
<font color="green" align="center"><?php echo htmlentities($_SESSION['msg']);?><?php echo
htmlentities($_SESSION['msg']="");?></font>

<div class="panel-body">
<form name="semester" method="post">
<div class="form-group">
<label for="semester">Add Semester </label>
<input type="text" class="form-control" id="semester" name="semester"
placeholder="semester" required />
</div>
<button type="submit" name="submit" class="btn btn-default">Submit</button>
</form>
</div>
</div>
</div>
</div>
<font color="red" align="center"><?php echo htmlentities($_SESSION['delmsg']);?><?php echo

25
ONLINE COURSE REGISTRATION

htmlentities($_SESSION['delmsg']="");?></font>
<div class="col-md-12">
<!-- Bordered Table -->
<div class="panel panel-default">
<div class="panel-heading">
Manage Semester
</div>
<!-- /.panel-heading -->
<div class="panel-body">
<div class="table-responsive table-bordered">
<table class="table">
<thead>
<tr>
<th>#</th>
<th>Semester</th>
<th>Creation Date</th>
<th>Action</th>
</tr>
</thead>
<tbody>
<?php
$sql=mysqli_query($con,"select * from semester");
$cnt=1;
while($row=mysqli_fetch_array($sql))
{
?>
<tr>
<td><?php echo $cnt;?></td>
<td><?php echo htmlentities($row['semester']);?></td>
<td><?php echo htmlentities($row['creationDate']);?></td>
<td>
<a href="semester.php?id=<?php echo $row['id']?>&del=delete" onClick="return confirm('Are
you sure you want to delete?')">
<button class="btn btn-danger">Delete</button>
</a>
</td>
</tr>
<?php
$cnt++;
} ?>
</tbody>
</table>
</div>
</div>
</div>
<!-- End Bordered Table -->
</div>
</div>

26
ONLINE COURSE REGISTRATION

</div>
</div>
<!-- CONTENT-WRAPPER SECTION END-->
<?php include('includes/footer.php');?>
<!-- FOOTER SECTION END-->
<!-- JAVASCRIPT AT THE BOTTOM TO REDUCE THE LOADING TIME -->
<!-- CORE JQUERY SCRIPTS -->
<script src="../assets/js/jquery-1.11.1.js"></script>
<!-- BOOTSTRAP SCRIPTS -->
<script src="../assets/js/bootstrap.js"></script>
</body>
</html>
<?php } ?>

Department

<?php
session_start();
include('includes/config.php');
if(strlen($_SESSION['alogin'])==0)
{
header('location:index.php');
}
Else
{
if(isset($_POST['submit']))
{
$department=$_POST['department'];
$ret=mysqli_query($con,"insert into department(department) values('$department')");
if($ret)
{
echo '<script>alert("Department Created Successfully !!")</script>';
echo '<script>window.location.href=deprtment.php</script>';
}else{
echo '<script>alert("Error : Department not created")</script>';
echo '<script>window.location.href=deprtment.php</script>';
}
}
//Delete the department
if(isset($_GET['del']))
{
$deptid=$_GET['id'];
mysqli_query($con,"delete from department where id = '$deptid'");
echo '<script>alert("Department deleted !!")</script>';
echo '<script>window.location.href=deprtment.php</script>';
}
?>

27
ONLINE COURSE REGISTRATION

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Admin | Department</title>
<link href="../assets/css/bootstrap.css" rel="stylesheet" />
<link href="../assets/css/font-awesome.css" rel="stylesheet" />
<link href="../assets/css/style.css" rel="stylesheet" />
</head>

<body>
<?php include('includes/header.php');?>
<!-- LOGO HEADER END-->
<?php if($_SESSION['alogin']!="")
{
include('includes/menubar.php');
}
?>
<!-- MENU SECTION END-->
<div class="content-wrapper">
<div class="container">
<div class="row">
<div class="col-md-12">
<h1 class="page-head-line">Department </h1>
</div>
</div>
<div class="row" >
<div class="col-md-3"></div>
<div class="col-md-6">
<div class="panel panel-default">
<div class="panel-heading">
Department
</div>
<font color="green" align="center"><?php echo htmlentities($_SESSION['msg']);?><?php echo
htmlentities($_SESSION['msg']="");?></font>

<div class="panel-body">
<form name="dept" method="post">
<div class="form-group">
<label for="department">Add Department </label>
<input type="text" class="form-control" id="department" name="department"
placeholder="department" required />
</div>
<button type="submit" name="submit" class="btn btn-default">Submit</button>
</form>
</div>
</div>
</div>

28
ONLINE COURSE REGISTRATION

</div>
<font color="red" align="center"><?php echo htmlentities($_SESSION['delmsg']);?><?php echo
htmlentities($_SESSION['delmsg']="");?></font>
<div class="col-md-12">
<!-- Bordered Table -->
<div class="panel panel-default">
<div class="panel-heading">
Manage Session
</div>
<!-- /.panel-heading -->
<div class="panel-body">
<div class="table-responsive table-bordered">
<table class="table">
<thead>
<tr>
<th>#</th>
<th>department</th>
<th>Creation Date</th>
<th>Action</th>
</tr>
</thead>
<tbody>
<?php
$sql=mysqli_query($con,"select * from department");
$cnt=1;
while($row=mysqli_fetch_array($sql))
{
?>
<tr>
<td><?php echo $cnt;?></td>
<td><?php echo htmlentities($row['department']);?></td>
<td><?php echo htmlentities($row['creationDate']);?></td>
<td>
<a href="department.php?id=<?php echo $row['id']?>&del=delete" onClick="return
confirm('Are you sure you want to delete?')">
<button class="btn btn-danger">Delete</button>
</a>
</td>
</tr>
<?php
$cnt++;
} ?>
</tbody>
</table>
</div>
</div>
</div>

29
ONLINE COURSE REGISTRATION

<!-- End Bordered Table -->


</div>
</div>
</div>
</div>
<!-- CONTENT-WRAPPER SECTION END-->
<?php include('includes/footer.php');?>
<!-- FOOTER SECTION END-->
<!-- JAVASCRIPT AT THE BOTTOM TO REDUCE THE LOADING TIME -->
<!-- CORE JQUERY SCRIPTS -->
<script src="../assets/js/jquery-1.11.1.js"></script>
<!-- BOOTSTRAP SCRIPTS -->
<script src="../assets/js/bootstrap.js"></script>
</body>
</html>
<?php } ?>

Course

<?php
session_start();
include('includes/config.php');
if(strlen($_SESSION['alogin'])==0)
{
header('location:index.php');
}
else{

//Code for Insertion


if(isset($_POST['submit']))
{
$coursecode=$_POST['coursecode'];
$coursename=$_POST['coursename'];
$courseunit=$_POST['courseunit'];
$seatlimit=$_POST['seatlimit'];
$ret=mysqli_query($con,"insert into course(courseCode,courseName,courseUnit,noofSeats)
values('$coursecode','$coursename','$courseunit','$seatlimit')");
if($ret)
{
echo '<script>alert("Course Created Successfully !!")</script>';
echo '<script>window.location.href=course.php</script>';
}else {
echo '<script>alert("Error : Course not created!!")</script>';
echo '<script>window.location.href=course.php</script>';
}
}

//Code for Insertion

30
ONLINE COURSE REGISTRATION

if(isset($_GET['del']))
{
mysqli_query($con,"delete from course where id = '".$_GET['id']."'");
echo '<script>alert("Course deleted!!")</script>';
echo '<script>window.location.href=course.php</script>';
}
?>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Admin | Course</title>
<link href="../assets/css/bootstrap.css" rel="stylesheet" />
<link href="../assets/css/font-awesome.css" rel="stylesheet" />
<link href="../assets/css/style.css" rel="stylesheet" />
</head>

<body>
<?php include('includes/header.php');?>
<!-- LOGO HEADER END-->
<?php if($_SESSION['alogin']!="")
{
include('includes/menubar.php');
}
?>
<!-- MENU SECTION END-->
<div class="content-wrapper">
<div class="container">
<div class="row">
<div class="col-md-12">
<h1 class="page-head-line">Course </h1>
</div>
</div>
<div class="row" >
<div class="col-md-3"></div>
<div class="col-md-6">
<div class="panel panel-default">
<div class="panel-heading">
Course
</div>
<font color="green" align="center"><?php echo htmlentities($_SESSION['msg']);?><?php echo
htmlentities($_SESSION['msg']="");?></font>

<div class="panel-body">
<form name="dept" method="post">
<div class="form-group">
<label for="coursecode">Course Code </label>

31
ONLINE COURSE REGISTRATION

<input type="text" class="form-control" id="coursecode" name="coursecode"


placeholder="Course Code" required />
</div>
<div class="form-group">
<label for="coursename">Course Name </label>
<input type="text" class="form-control" id="coursename" name="coursename"
placeholder="Course Name" required />
</div>
<div class="form-group">
<label for="courseunit">Course unit </label>
<input type="text" class="form-control" id="courseunit" name="courseunit"
placeholder="Course Unit" required />
</div>
<div class="form-group">
<label for="seatlimit">Seat limit </label>
<input type="text" class="form-control" id="seatlimit" name="seatlimit" placeholder="Seat
limit" required />
</div>
<button type="submit" name="submit" class="btn btn-default">Submit</button>
</form>
</div>
</div>
</div>
</div>
<font color="red" align="center"><?php echo htmlentities($_SESSION['delmsg']);?><?php echo
htmlentities($_SESSION['delmsg']="");?></font>
<div class="col-md-12">
<!-- Bordered Table -->
<div class="panel panel-default">
<div class="panel-heading">
Manage Course
</div>
<!-- /.panel-heading -->
<div class="panel-body">
<div class="table-responsive table-bordered">
<table class="table">
<thead>
<tr>
<th>#</th>
<th>Course Code</th>
<th>Course Name </th>
<th>Course Unit</th>
<th>Seat limit</th>
<th>Creation Date</th>
<th>Action</th>
</tr>
</thead>
<tbody>

32
ONLINE COURSE REGISTRATION

<?php
$sql=mysqli_query($con,"select * from course");
$cnt=1;
while($row=mysqli_fetch_array($sql))
{
?>
<tr>
<td><?php echo $cnt;?></td>
<td><?php echo htmlentities($row['courseCode']);?></td>
<td><?php echo htmlentities($row['courseName']);?></td>
<td><?php echo htmlentities($row['courseUnit']);?></td>
<td><?php echo htmlentities($row['noofSeats']);?></td>
<td><?php echo htmlentities($row['creationDate']);?></td>
<td>
<a href="edit-course.php?id=<?php echo $row['id']?>">
<button class="btn btn-primary"><i class="fa fa-edit "></i> Edit</button> </a>
<a href="course.php?id=<?php echo $row['id']?>&del=delete" onClick="return confirm('Are
you sure you want to delete?')">
<button class="btn btn-danger">Delete</button>
</a>
</td>
</tr>
<?php
$cnt++;
} ?>
</tbody>
</table>
</div>
</div>
</div>
<!-- End Bordered Table -->
</div>
</div>
</div>
</div>
<!-- CONTENT-WRAPPER SECTION END-->
<?php include('includes/footer.php');?>
<!-- FOOTER SECTION END-->
<!-- JAVASCRIPT AT THE BOTTOM TO REDUCE THE LOADING TIME -->
<!-- CORE JQUERY SCRIPTS -->
<script src="../assets/js/jquery-1.11.1.js"></script>
<!-- BOOTSTRAP SCRIPTS -->
<script src="../assets/js/bootstrap.js"></script>
</body>
</html>
<?php } ?>

33
ONLINE COURSE REGISTRATION

Registration

<?php
session_start();
include('includes/config.php');
if(strlen($_SESSION['alogin'])==0)
{
header('location:index.php');
}
else{

if(isset($_POST['submit']))
{
$studentname=$_POST['studentname'];
$studentregno=$_POST['studentregno'];
$password=md5($_POST['password']);
$pincode = rand(100000,999999);
$ret=mysqli_query($con,"insert into students(studentName,StudentRegno,password,pincode)
values('$studentname','$studentregno','$password','$pincode')");
if($ret)
{
echo '<script>alert("Student Registered Successfully. Pincode is "+"'.$pincode.'")</script>';
echo '<script>window.location.href=manage-students.php</script>';
}else{
echo '<script>alert("Something went wrong. Please try again.")</script>';
echo '<script>window.location.href=manage-students.php</script>';
}
}
?>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />
<meta name="description" content="" />
<meta name="author" content="" />
<title>Admin | Student Registration</title>
<link href="../assets/css/bootstrap.css" rel="stylesheet" />
<link href="../assets/css/font-awesome.css" rel="stylesheet" />
<link href="../assets/css/style.css" rel="stylesheet" />
</head>
<body>
<?php include('includes/header.php');?>
<!-- LOGO HEADER END-->
<?php if($_SESSION['alogin']!="")
{
include('includes/menubar.php');

34
ONLINE COURSE REGISTRATION

}
?>
<!-- MENU SECTION END-->
<div class="content-wrapper">
<div class="container">
<div class="row">
<div class="col-md-12">
<h1 class="page-head-line">Student Registration </h1>
</div>
</div>
<div class="row" >
<div class="col-md-3"></div>
<div class="col-md-6">
<div class="panel panel-default">
<div class="panel-heading">
Student Registration
</div>
<font color="green" align="center"><?php echo htmlentities($_SESSION['msg']);?><?php echo
htmlentities($_SESSION['msg']="");?></font>

<div class="panel-body">
<form name="dept" method="post">
<div class="form-group">
<label for="studentname">Student Name </label>
<input type="text" class="form-control" id="studentname" name="studentname"
placeholder="Student Name" required />
</div>
<div class="form-group">
<label for="studentregno">Student Reg No </label>
<input type="text" class="form-control" id="studentregno" name="studentregno"
onBlur="userAvailability()" placeholder="Student Reg no" required />
<span id="user-availability-status1" style="font-size:12px;">
</div>

<div class="form-group">
<label for="password">Password </label>
<input type="password" class="form-control" id="password" name="password"
placeholder="Enter password" required />
</div>
<button type="submit" name="submit" id="submit" class="btn btn-default">Submit</button>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</div>

35
ONLINE COURSE REGISTRATION

<?php include('includes/footer.php');?>
<script src="../assets/js/jquery-1.11.1.js"></script>
<script src="../assets/js/bootstrap.js"></script>
<script>
function userAvailability() {
$("#loaderIcon").show();
jQuery.ajax({
url: "check_availability.php",
data:'regno='+$("#studentregno").val(),
type: "POST",
success:function(data){
$("#user-availability-status1").html(data);
$("#loaderIcon").hide();
},
error:function (){}
});
}
</script>
</body>
</html>
<?php } ?>

Enroll history

<?php
session_start();
include('includes/config.php');
if(strlen($_SESSION['alogin'])==0)
{
header('location:index.php');
}
else{
?>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />
<meta name="description" content="" />
<meta name="author" content="" />
<title>Enroll History</title>
<link href="../assets/css/bootstrap.css" rel="stylesheet" />
<link href="../assets/css/font-awesome.css" rel="stylesheet" />
<link href="../assets/css/style.css" rel="stylesheet" />
</head>
<body>
<?php include('includes/header.php');?>

36
ONLINE COURSE REGISTRATION

<!-- LOGO HEADER END-->


<?php if($_SESSION['alogin']!="")
{
include('includes/menubar.php');
}
?>
<!-- MENU SECTION END-->
<div class="content-wrapper">
<div class="container">
<div class="row">
<div class="col-md-12">
<h1 class="page-head-line">Enroll History </h1>
</div>
</div>
<div class="row" >

<div class="col-md-12">
<!-- Bordered Table -->
<div class="panel panel-default">
<div class="panel-heading">
Enroll History
</div>
<!-- /.panel-heading -->
<div class="panel-body">
<div class="table-responsive table-bordered">
<table class="table">
<thead>
<tr>
<th>#</th>
<th>Student Name </th>
<th>Student Reg no </th>
<th>Course Name </th>
<th>Session </th>
<th>Semester</th>
<th>Enrollment Date</th>
<th>Action</th>
</tr>
</thead>
<tbody>
<?php
$sql=mysqli_query($con,"select courseenrolls.course as cid, course.courseName as
courname,session.session as session,department.department as dept,courseenrolls.enrollDate as
edate ,semester.semester as sem,students.studentName as sname,students.StudentRegno as
sregno from courseenrolls join course on course.id=courseenrolls.course join session on
session.id=courseenrolls.session join department on department.id=courseenrolls.department
join semester on semester.id=courseenrolls.semester join students on
students.StudentRegno=courseenrolls.studentRegno ");
$cnt=1;

37
ONLINE COURSE REGISTRATION

while($row=mysqli_fetch_array($sql))
{
?>
<tr>
<td><?php echo $cnt;?></td>
<td><?php echo htmlentities($row['sname']);?></td>
<td><?php echo htmlentities($row['sregno']);?></td>
<td><?php echo htmlentities($row['courname']);?></td>
<td><?php echo htmlentities($row['dept']);?></td>

<td><?php echo htmlentities($row['sem']);?></td>


<td><?php echo htmlentities($row['edate']);?></td>
<td>
<a href="print.php?id=<?php echo $row['cid']?>" target="_blank">
<button class="btn btn-primary"><i class="fa fa-print "></i> Print</button> </a>
</td>
</tr>
<?php
$cnt++;
} ?>
</tbody>
</table>
</div>
</div>
</div>
<!-- End Bordered Table -->
</div>
</div>
</div>
</div>
<!-- CONTENT-WRAPPER SECTION END-->
<?php include('includes/footer.php');?>
<!-- FOOTER SECTION END-->
<!-- JAVASCRIPT AT THE BOTTOM TO REDUCE THE LOADING TIME -->
<!-- CORE JQUERY SCRIPTS -->
<script src="../assets/js/jquery-1.11.1.js"></script>
<!-- BOOTSTRAP SCRIPTS -->
<script src="../assets/js/bootstrap.js"></script>
</body>
</html>
<?php } ?>

Change password

<?php
session_start();
include('includes/config.php');
if(strlen($_SESSION['alogin'])==0)

38
ONLINE COURSE REGISTRATION

{
header('location:index.php');
}
else{
date_default_timezone_set('Asia/Kolkata');// change according timezone
$currentTime = date( 'd-m-Y h:i:s A', time () );
if(isset($_POST['submit']))
{
$sql=mysqli_query($con,"SELECT password FROM admin where
password='".md5($_POST['cpass'])."' && username='".$_SESSION['alogin']."'");
$num=mysqli_fetch_array($sql);
if($num>0)
{
$con=mysqli_query($con,"update admin set password='".md5($_POST['newpass'])."',
updationDate='$currentTime' where username='".$_SESSION['alogin']."'");
echo '<script>alert("Password Changed Successfully !!")</script>';
echo '<script>window.location.href=change-password.php</script>';
}else {
echo '<script>alert("Old Password not match !!")</script>';
echo '<script>window.location.href=change-password.php</script>';
}
}
?>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<title>Admin | Change Password</title>
<link href="../assets/css/bootstrap.css" rel="stylesheet" />
<link href="../assets/css/font-awesome.css" rel="stylesheet" />
<link href="../assets/css/style.css" rel="stylesheet" />
</head>
<script type="text/javascript">
function valid()
{
if(document.chngpwd.cpass.value=="")
{
alert("Current Password Filed is Empty !!");
document.chngpwd.cpass.focus();
return false;
}
else if(document.chngpwd.newpass.value=="")
{
alert("New Password Filed is Empty !!");
document.chngpwd.newpass.focus();
return false;
}

39
ONLINE COURSE REGISTRATION

else if(document.chngpwd.cnfpass.value=="")
{
alert("Confirm Password Filed is Empty !!");
document.chngpwd.cnfpass.focus();
return false;
}
else if(document.chngpwd.newpass.value!= document.chngpwd.cnfpass.value)
{
alert("Password and Confirm Password Field do not match !!");
document.chngpwd.cnfpass.focus();
return false;
}
return true;
}
</script>
<body>
<?php include('includes/header.php');?>
<!-- LOGO HEADER END-->
<?php if($_SESSION['alogin']!="")
{
include('includes/menubar.php');
}
?>
<!-- MENU SECTION END-->
<div class="content-wrapper">
<div class="container">
<div class="row">
<div class="col-md-12">
<h1 class="page-head-line">Admin Change Password </h1>
</div>
</div>
<div class="row" >
<div class="col-md-3"></div>
<div class="col-md-6">
<div class="panel panel-default">
<div class="panel-heading">
Change Password
</div>
<font color="green" align="center"><?php echo htmlentities($_SESSION['msg']);?><?php echo
htmlentities($_SESSION['msg']="");?></font>
<div class="panel-body">
<form name="chngpwd" method="post" onSubmit="return valid();">
<div class="form-group">
<label for="exampleInputPassword1">Current Password</label>
<input type="password" class="form-control" id="exampleInputPassword1" name="cpass"
placeholder="Password" />
</div>
<div class="form-group">

40
ONLINE COURSE REGISTRATION

<label for="exampleInputPassword1">New Password</label>


<input type="password" class="form-control" id="exampleInputPassword2" name="newpass"
placeholder="Password" />
</div>
<div class="form-group">
<label for="exampleInputPassword1">Confirm Password</label>
<input type="password" class="form-control" id="exampleInputPassword3" name="cnfpass"
placeholder="Password" />
</div>
<button type="submit" name="submit" class="btn btn-default">Submit</button>
<hr />
</form>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- CONTENT-WRAPPER SECTION END-->
<?php include('includes/footer.php');?>
<!-- FOOTER SECTION END-->
<!-- JAVASCRIPT AT THE BOTTOM TO REDUCE THE LOADING TIME -->
<!-- CORE JQUERY SCRIPTS -->
<script src="../assets/js/jquery-1.11.1.js"></script>
<!-- BOOTSTRAP SCRIPTS -->
<script src="../assets/js/bootstrap.js"></script>
</body>
</html>
<?php } ?>

User-Log

<?php
session_start();
include('includes/config.php');
if(strlen($_SESSION['alogin'])==0)
{
header('location:index.php');
}
else{
?>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />
<meta name="description" content="" />

41
ONLINE COURSE REGISTRATION

<meta name="author" content="" />


<title>Enroll History</title>
<link href="../assets/css/bootstrap.css" rel="stylesheet" />
<link href="../assets/css/font-awesome.css" rel="stylesheet" />
<link href="../assets/css/style.css" rel="stylesheet" />
</head>
<body>
<?php include('includes/header.php');?>
<!-- LOGO HEADER END-->
<?php if($_SESSION['alogin']!="")
{
include('includes/menubar.php');
}
?>
<!-- MENU SECTION END-->
<div class="content-wrapper">
<div class="container">
<div class="row">
<div class="col-md-12">
<h1 class="page-head-line">Enroll History </h1>
</div>
</div>
<div class="row" >
<div class="col-md-12">
<!-- Bordered Table -->
<div class="panel panel-default">
<div class="panel-heading">
Enroll History
</div>
<!-- /.panel-heading -->
<div class="panel-body">
<div class="table-responsive table-bordered">
<table class="table">
<thead>
<tr>
<th>#</th>
<th>Student Reg no </th>
<th>IP </th>
<th>Login Time </th>
<th>Logout Time</th>
<th>Status</th>
</tr>
</thead>
<tbody>
<?php
$sql=mysqli_query($con,"select * from userlog");
$cnt=1;
while($row=mysqli_fetch_array($sql))

42
ONLINE COURSE REGISTRATION

{
?>
<tr>
<td><?php echo $cnt;?></td>
<td><?php echo htmlentities($row['studentRegno']);?></td>
<td><?php echo htmlentities($row['userip']);?></td>
<td><?php echo htmlentities($row['loginTime']);?></td>
<td><?php echo htmlentities($row['logout']);?></td>
<td><?php echo htmlentities($row['status']);?></td>
</tr>
<?php
$cnt++;
} ?>
</tbody>
</table>
</div>
</div>
</div>
<!-- End Bordered Table -->
</div>
</div>
</div>
</div>
<!-- CONTENT-WRAPPER SECTION END-->
<?php include('includes/footer.php');?>
<!-- FOOTER SECTION END-->
<!-- JAVASCRIPT AT THE BOTTOM TO REDUCE THE LOADING TIME -->
<!-- CORE JQUERY SCRIPTS -->
<script src="../assets/js/jquery-1.11.1.js"></script>
<!-- BOOTSTRAP SCRIPTS -->
<script src="../assets/js/bootstrap.js"></script>
</body>
</html>
<?php } ?>

Student:-My Profile

<?php
session_start();
include('includes/config.php');
error_reporting(0);
if(strlen($_SESSION['login'])==0)
{
header('location:index.php');
}
else{
if(isset($_POST['submit']))

43
ONLINE COURSE REGISTRATION

{
$studentname=$_POST['studentname'];
$photo=$_FILES["photo"]["name"];
$cgpa=$_POST['cgpa'];
move_uploaded_file($_FILES["photo"]["tmp_name"],"studentphoto/".$_FILES["photo"]["name
"]);
$ret=mysqli_query($con,"update students set
studentName='$studentname',studentPhoto='$photo',cgpa='$cgpa' where
StudentRegno='".$_SESSION['login']."'");
if($ret)
{
echo '<script>alert("Student Record updated Successfully !!")</script>';
echo '<script>window.location.href=my-profile.php</script>';
}else{
echo '<script>alert("Something went wrong . Please try again.!")</script>';
echo '<script>window.location.href=my-profile.php</script>';
}
}
?>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />
<meta name="description" content="" />
<meta name="author" content="" />
<title>Student Profile</title>
<link href="assets/css/bootstrap.css" rel="stylesheet" />
<link href="assets/css/font-awesome.css" rel="stylesheet" />
<link href="assets/css/style.css" rel="stylesheet" />
</head>
<body>
<?php include('includes/header.php');?>
<!-- LOGO HEADER END-->
<?php if($_SESSION['login']!="")
{
include('includes/menubar.php');
}
?>
<!-- MENU SECTION END-->
<div class="content-wrapper">
<div class="container">
<div class="row">
<div class="col-md-12">
<h1 class="page-head-line">Student Registration </h1>
</div>
</div>

44
ONLINE COURSE REGISTRATION

<div class="row" >


<div class="col-md-3"></div>
<div class="col-md-6">
<div class="panel panel-default">
<div class="panel-heading">
Student Registration
</div>
<font color="green" align="center"><?php echo htmlentities($_SESSION['msg']);?><?php echo
htmlentities($_SESSION['msg']="");?></font>
<?php $sql=mysqli_query($con,"select * from students where
StudentRegno='".$_SESSION['login']."'");
$cnt=1;
while($row=mysqli_fetch_array($sql))
{ ?>
<div class="panel-body">
<form name="dept" method="post" enctype="multipart/form-data">
<div class="form-group">
<label for="studentname">Student Name </label>
<input type="text" class="form-control" id="studentname" name="studentname" value="<?php
echo htmlentities($row['studentName']);?>" />
</div>
<div class="form-group">
<label for="studentregno">Student Reg No </label>
<input type="text" class="form-control" id="studentregno" name="studentregno" value="<?php
echo htmlentities($row['StudentRegno']);?>" placeholder="Student Reg no" readonly />
</div>
<div class="form-group">
<label for="Pincode">Pincode </label>
<input type="text" class="form-control" id="Pincode" name="Pincode" readonly value="<?php
echo htmlentities($row['pincode']);?>" required />
</div>
<div class="form-group">
<label for="CGPA">CGPA </label>
<input type="text" class="form-control" id="cgpa" name="cgpa" value="<?php echo
htmlentities($row['cgpa']);?>" required />
</div>
<div class="form-group">
<label for="Pincode">Student Photo </label>
<?php if($row['studentPhoto']==""){ ?>
<img src="studentphoto/noimage.png" width="200" height="200"><?php } else {?>
<img src="studentphoto/<?php echo htmlentities($row['studentPhoto']);?>" width="200"
height="200">
<?php } ?>
</div>
<div class="form-group">
<label for="Pincode">Upload New Photo </label>
<input type="file" class="form-control" id="photo" name="photo" value="<?php echo
htmlentities($row['studentPhoto']);?>" />

45
ONLINE COURSE REGISTRATION

</div>
<?php } ?>

<button type="submit" name="submit" id="submit" class="btn btn-default">Update</button>


</form>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<?php include('includes/footer.php');?>
<script src="assets/js/jquery-1.11.1.js"></script>
<script src="assets/js/bootstrap.js"></script>
</body>
</html>
<?php } ?>

Enroll

<?php
session_start();
include('includes/config.php');
error_reporting(0);
if(strlen($_SESSION['login'])==0 or strlen($_SESSION['pcode'])==0)
{
header('location:index.php');
}
else{
if(isset($_POST['submit']))
{
$studentregno=$_POST['studentregno'];
$pincode=$_POST['Pincode'];
$session=$_POST['session'];
$dept=$_POST['department'];
$level=$_POST['level'];
$course=$_POST['course'];
$sem=$_POST['sem'];
$ret=mysqli_query($con,"insert into
courseenrolls(studentRegno,pincode,session,department,level,course,semester)
values('$studentregno','$pincode','$session','$dept','$level','$course','$sem')");
if($ret)
{
echo '<script>alert("Enroll Successfully !!")</script>';
echo '<script>window.location.href=enroll.php</script>';
}else{
echo '<script>alert("Error : Not Enroll")</script>';

46
ONLINE COURSE REGISTRATION

echo '<script>window.location.href=enroll.php</script>';
}
}
?>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />
<meta name="description" content="" />
<meta name="author" content="" />
<title>Course Enroll</title>
<link href="assets/css/bootstrap.css" rel="stylesheet" />
<link href="assets/css/font-awesome.css" rel="stylesheet" />
<link href="assets/css/style.css" rel="stylesheet" />
</head>

<body>
<?php include('includes/header.php');?>
<!-- LOGO HEADER END-->
<?php if($_SESSION['login']!="")
{
include('includes/menubar.php');
}
?>
<!-- MENU SECTION END-->
<div class="content-wrapper">
<div class="container">
<div class="row">
<div class="col-md-12">
<h1 class="page-head-line">Course Enroll </h1>
</div>
</div>
<div class="row" >
<div class="col-md-3"></div>
<div class="col-md-6">
<div class="panel panel-default">
<div class="panel-heading">
Course Enroll
</div>
<font color="green" align="center"><?php echo htmlentities($_SESSION['msg']);?><?php echo
htmlentities($_SESSION['msg']="");?></font>
<?php $sql=mysqli_query($con,"select * from students where
StudentRegno='".$_SESSION['login']."'");
$cnt=1;
while($row=mysqli_fetch_array($sql))
{ ?>

47
ONLINE COURSE REGISTRATION

<div class="panel-body">
<form name="dept" method="post" enctype="multipart/form-data">
<div class="form-group">
<label for="studentname">Student Name </label>
<input type="text" class="form-control" id="studentname" name="studentname" value="<?php
echo htmlentities($row['studentName']);?>" />
</div>
<div class="form-group">
<label for="studentregno">Student Reg No </label>
<input type="text" class="form-control" id="studentregno" name="studentregno" value="<?php
echo htmlentities($row['StudentRegno']);?>" placeholder="Student Reg no" readonly />
</div>
<div class="form-group">
<label for="Pincode">Pincode </label>
<input type="text" class="form-control" id="Pincode" name="Pincode" readonly value="<?php
echo htmlentities($row['pincode']);?>" required />
</div>
<div class="form-group">
<label for="Pincode">Student Photo </label>
<?php if($row['studentPhoto']==""){ ?>
<img src="studentphoto/noimage.png" width="200" height="200"><?php } else {?>
<img src="studentphoto/<?php echo htmlentities($row['studentPhoto']);?>" width="200"
height="200">
<?php } ?>
</div>
<?php } ?>
<div class="form-group">
<label for="Session">Session </label>
<select class="form-control" name="session" required="required">
<option value="">Select Session</option>
<?php
$sql=mysqli_query($con,"select * from session");
while($row=mysqli_fetch_array($sql))
{
?>
<option value="<?php echo htmlentities($row['id']);?>"><?php echo
htmlentities($row['session']);?></option>
<?php } ?>
</select>
</div>
<div class="form-group">
<label for="Department">Department </label>
<select class="form-control" name="department" required="required">
<option value="">Select Depertment</option>
<?php
$sql=mysqli_query($con,"select * from department");
while($row=mysqli_fetch_array($sql))

48
ONLINE COURSE REGISTRATION

{
?>
<option value="<?php echo htmlentities($row['id']);?>"><?php echo
htmlentities($row['department']);?></option>
<?php } ?>
</select>
</div>
<div class="form-group">
<label for="Level">Level </label>
<select class="form-control" name="level" required="required">
<option value="">Select Level</option>
<?php
$sql=mysqli_query($con,"select * from level");
while($row=mysqli_fetch_array($sql))
{
?>
<option value="<?php echo htmlentities($row['id']);?>"><?php echo
htmlentities($row['level']);?></option>
<?php } ?>
</select>
</div>
<div class="form-group">
<label for="Semester">Semester </label>
<select class="form-control" name="sem" required="required">
<option value="">Select Semester</option>
<?php
$sql=mysqli_query($con,"select * from semester");
while($row=mysqli_fetch_array($sql))
{
?>
<option value="<?php echo htmlentities($row['id']);?>"><?php echo
htmlentities($row['semester']);?></option>
<?php } ?>
</select>
</div>
<div class="form-group">
<label for="Course">Course </label>
<select class="form-control" name="course" id="course" onBlur="courseAvailability()"
required="required">
<option value="">Select Course</option>
<?php
$sql=mysqli_query($con,"select * from course");
while($row=mysqli_fetch_array($sql))
{
?>
<option value="<?php echo htmlentities($row['id']);?>"><?php echo
htmlentities($row['courseName']);?></option>
<?php } ?>

49
ONLINE COURSE REGISTRATION

</select>
<span id="course-availability-status1" style="font-size:12px;">
</div>

<button type="submit" name="submit" id="submit" class="btn btn-default">Enroll</button>


</form>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<?php include('includes/footer.php');?>
<script src="assets/js/jquery-1.11.1.js"></script>
<script src="assets/js/bootstrap.js"></script>
<script>
function courseAvailability() {
$("#loaderIcon").show();
jQuery.ajax({
url: "check_availability.php",
data:'cid='+$("#course").val(),
type: "POST",
success:function(data){
$("#course-availability-status1").html(data);
$("#loaderIcon").hide();
},
error:function (){}
});
}
</script>
</body>
</html>
<?php } ?>

Pin code Verification

<?php
session_start();
include('includes/config.php');
error_reporting(0);
if(strlen($_SESSION['login'])==0)
{
header('location:index.php');
}
else{

50
ONLINE COURSE REGISTRATION

date_default_timezone_set('Asia/Kolkata');// change according timezone


$currentTime = date( 'd-m-Y h:i:s A', time () );
if(isset($_POST['submit']))
{
$sql=mysqli_query($con,"SELECT * FROM students where
pincode='".trim($_POST['pincode'])."' && StudentRegno='".$_SESSION['login']."'");
$num=mysqli_fetch_array($sql);
if($num>0)
{
$_SESSION['pcode']=$_POST['pincode'];
header("location:enroll.php");
}else{
echo '<script>alert("Error :Wrong Pincode. Please Enter a Valid Pincode !!")</script>';
echo '<script>window.location.href=my-pincode-verification.php</script>';
}
}
?>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />
<meta name="description" content="" />
<meta name="author" content="" />
<title>Pincode Verification</title>
<link href="assets/css/bootstrap.css" rel="stylesheet" />
<link href="assets/css/font-awesome.css" rel="stylesheet" />
<link href="assets/css/style.css" rel="stylesheet" />
</head>

<body>
<?php include('includes/header.php');?>
<!-- LOGO HEADER END-->
<?php if($_SESSION['login']!="")
{
include('includes/menubar.php');
}
?>
<!-- MENU SECTION END-->
<div class="content-wrapper">
<div class="container">
<div class="row">
<div class="col-md-12">
<h1 class="page-head-line">Student Pincode Verification</h1>
</div>
</div>
<div class="row" >

51
ONLINE COURSE REGISTRATION

<div class="col-md-3"></div>
<div class="col-md-6">
<div class="panel panel-default">
<div class="panel-heading">
Pincode Verification
</div>
<font color="red" align="center"><?php echo htmlentities($_SESSION['msg']);?><?php echo
htmlentities($_SESSION['msg']="");?></font>
<div class="panel-body">
<form name="pincodeverify" method="post">
<div class="form-group">
<label for="pincode">Enter Pincode</label>
<input type="password" class="form-control" id="pincode" name="pincode"
placeholder="Pincode" required />
</div>
<button type="submit" name="submit" class="btn btn-default">Verify</button>
<hr />
</form>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- CONTENT-WRAPPER SECTION END-->
<?php include('includes/footer.php');?>
<!-- FOOTER SECTION END-->
<!-- JAVASCRIPT AT THE BOTTOM TO REDUCE THE LOADING TIME -->
<!-- CORE JQUERY SCRIPTS -->
<script src="assets/js/jquery-1.11.1.js"></script>
<!-- BOOTSTRAP SCRIPTS -->
<script src="assets/js/bootstrap.js"></script>
</body>
</html>
<?php } ?>

Print

<?php
session_start();
include('includes/config.php');
error_reporting(0);
if(strlen($_SESSION['login'])==0)
{
header('location:index.php');
}else{
?>

52
ONLINE COURSE REGISTRATION

<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Course Enrollment Print</title>

<style>
.invoice-box{
max-width:800px;
margin:auto;
padding:20px;
border:1px solid #eee;
box-shadow:0 0 10px rgba(0, 0, 0, .15);
font-size:16px;
line-height:18px;
font-family:'Helvetica Neue', 'Helvetica', Helvetica, Arial, sans-serif;
color:#555;
}
.invoice-box table{
width:100%;
line-height:inherit;
text-align:left;
}
.invoice-box table td{
padding:5px;
vertical-align:top;
}
.invoice-box table tr td:nth-child(2){
text-align:right;
}
.invoice-box table tr.top table td{
padding-bottom:10px;
}
.invoice-box table tr.top table td.title{
font-size:45px;
line-height:30px;
color:#333;
}
.invoice-box table tr.information table td{
padding-bottom:20px;
}
.invoice-box table tr.heading td{
background:#eee;
border-bottom:1px solid #ddd;
font-weight:bold;
}

.invoice-box table tr.details td{

53
ONLINE COURSE REGISTRATION

padding-bottom:20px;
}
.invoice-box table tr.item td{
border-bottom:1px solid #eee;
}
.invoice-box table tr.item.last td{
border-bottom:none;
}
.invoice-box table tr.total td:nth-child(2){
border-top:2px solid #eee;
font-weight:bold;
}
@media only screen and (max-width: 600px) {
.invoice-box table tr.top table td{
width:100%;
display:block;
text-align:center;
}
.invoice-box table tr.information table td{
width:100%;
display:block;
text-align:center;
}
}
</style>
</head>
<body>
<div class="invoice-box">
<?php
$cid=intval($_GET['id']);
$sql=mysqli_query($con,"select course.courseName as courname,course.courseCode as
ccode,course.courseUnit as cunit,session.session as session,department.department as
dept,level.level as level,courseenrolls.enrollDate as edate,semester.semester as sem
,students.studentName as studentname,students.studentPhoto as photo,students.cgpa as
scgpa,students.creationdate as studentregdate from courseenrolls join course on
course.id=courseenrolls.course join session on session.id=courseenrolls.session join department
on department.id=courseenrolls.department join level on level.id=courseenrolls.level join
students on students.StudentRegno=courseenrolls.StudentRegno join semester on
semester.id=courseenrolls.semester where courseenrolls.studentRegno='".$_SESSION['login']."'
and courseenrolls.course='$cid'");
$cnt=1;
while($row=mysqli_fetch_array($sql))
{?>
<table cellpadding="0" cellspacing="0">
<tr class="top">
<td colspan="2">
<table>
<tr>

54
ONLINE COURSE REGISTRATION

<td class="title">
<?php if($row['photo']==""){ ?>
<img src="studentphoto/noimage.png" width="200" height="200"><?php } else {?>
<img src="studentphoto/<?php echo htmlentities($row['photo']);?>" width="200" height="200">
<?php } ?>
</td>
<td>
<b> Reg No: </b><?php echo htmlentities($_SESSION['login']);?><br>
<b> Student Name: </b> <?php echo htmlentities($row['studentname']);?><br>
<b> Student Reg Date:</b> <?php echo htmlentities($row['studentregdate']);?><br>
<b> Student Course Enroll Date:</b> <?php echo htmlentities($row['edate']);?><br>
</td>
</tr>
</table>
</td>
</tr>
<tr class="heading">
<td>
Course Details
</td>
<td>
</td>
</tr>
<tr class="details">
<td>
Course Code
</td>
<td>
<?php echo htmlentities($row['ccode']);?>
</td>
</tr>
<tr class="details">
<td>
Course Name
</td>
<td>
<?php echo htmlentities($row['courname']);?>
</td>
</tr>
<tr class="details">
<td>
Course unit
</td>
<td>
<?php echo htmlentities($row['cunit']);?>
</td>
</tr>
<tr class="heading">

55
ONLINE COURSE REGISTRATION

<td>
Other Details
</td>
<td>
</td>
</tr>
<tr class="item">
<td>
Session
</td>
<td>
<?php echo htmlentities($row['session']);?>
</td>
</tr>
<tr class="item">
<td>
Department
</td>
<td>
<?php echo htmlentities($row['dept']);?>
</td>
</tr>
<tr class="item">
<td>
Level
</td>
<td>
<?php echo htmlentities($row['level']);?>
</td>
</tr>
<tr class="item">
<td>
CGPA
</td>
<td>
<?php echo htmlentities($row['scgpa']);?>
</td>
</tr>
<tr class="item last">
<td>
Semester
</td>
<td>
<?php echo htmlentities($row['sem']);?>
</td>
</tr>
</table>
<?php } ?>

56
ONLINE COURSE REGISTRATION

</div>
</body>
</html>
<?php } ?>

News-Details

<?php
session_start();
error_reporting(0);
include("includes/config.php");
if(isset($_POST['submit']))
{
$regno=$_POST['regno'];
$password=md5($_POST['password']);
$query=mysqli_query($con,"SELECT * FROM students WHERE StudentRegno='$regno' and
password='$password'");
$num=mysqli_fetch_array($query);
if($num>0)
{
$extra="change-password.php";//
$_SESSION['login']=$_POST['regno'];
$_SESSION['id']=$num['studentRegno'];
$_SESSION['sname']=$num['studentName'];
$uip=$_SERVER['REMOTE_ADDR'];
$status=1;
$log=mysqli_query($con,"insert into userlog(studentRegno,userip,status)
values('".$_SESSION['login']."','$uip','$status')");
}
else
{
$_SESSION['errmsg']="Invalid Reg no or Password";
$extra="index.php";
$host = $_SERVER['HTTP_HOST'];
$uri = rtrim(dirname($_SERVER['PHP_SELF']),'/\\');
header("location:http:index.php");
}
}
?>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />
<meta name="description" content="" />
<meta name="author" content="" />

57
ONLINE COURSE REGISTRATION

<title>Student Login</title>
<link href="assets/css/bootstrap.css" rel="stylesheet" />
<link href="assets/css/font-awesome.css" rel="stylesheet" />
<link href="assets/css/style.css" rel="stylesheet" />
</head>
<body>
<?php include('includes/header.php');?>
<section class="menu-section">
<div class="container">
<div class="row">
<div class="col-md-12">
<div class="navbar-collapse collapse ">
<ul id="menu-top" class="nav navbar-nav navbar-right">
<li><a href="index.php">Home </a></li>
<li><a href="admin/">Admin Login </a></li>
<li><a href="index.php">Student Login</a></li>
</ul>
</div>
</div>
</div>
</div>
</section>
<div class="content-wrapper">
<div class="container">
<div class="row">
<div class="col-md-12">
<h4 class="page-head-line">News Details </h4>
</div>
</div>
<div class="col-md-12">
<div class="alert alert-info">
<ul>
<?php $nid=$_GET['nid'];
$sql=mysqli_query($con,"select * from news where id='$nid'");
$cnt=1;
while($row=mysqli_fetch_array($sql))
{?>
<h3><?php echo htmlentities($row['newstitle']);?></h3>
<small><?php echo htmlentities($row['postingDate']);?></small>
<hr />
<p><?php echo htmlentities($row['newsDescription']);?></p>
<?php } ?>
</ul>
</marquee>
</div>
</div>
</div>
</div>

58
ONLINE COURSE REGISTRATION

</div>
<!-- CONTENT-WRAPPER SECTION END-->
<?php include('includes/footer.php');?>
<!-- FOOTER SECTION END-->
<!-- JAVASCRIPT AT THE BOTTOM TO REDUCE THE LOADING TIME -->
<!-- CORE JQUERY SCRIPTS -->
<script src="assets/js/jquery-1.11.1.js"></script>
<!-- BOOTSTRAP SCRIPTS -->
<script src="assets/js/bootstrap.js"></script>
</body>
</html>

Logout

<?php
session_start();
include("includes/config.php");
$_SESSION['login']=="";
date_default_timezone_set('Asia/Kolkata');
$ldate=date( 'd-m-Y h:i:s A', time () );
$uid=$_SESSION['login'];
mysqli_query($con,"UPDATE userlog SET logout = '$ldate' WHERE studentRegno = '$uid'
ORDER BY id DESC LIMIT 1");
session_unset();
$_SESSION['errmsg']="You have successfully logout";
?>
<script language="javascript">
document.location="index.php";
</script>

59
ONLINE COURSE REGISTRATION

5. TESTING

60
ONLINE COURSE REGISTRATION

Implementation and System Testing


After all phase have been perfectly done, the system will be implemented to the
server and the system can be used.

System Testing

The goal of the system testing process was to determine all faults in our project .The
program was subjected to a set of test inputs and many explanations were made and based
on these explanations 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

UNIT TESTING
Unit testing is commenced when a unit has been created and effectively reviewed
.In order to test a single module we need to provide a complete environment i.e.
besides the section we would require

• The procedures belonging to other units that the unit under test calls

• Non local data structures that module accesses

• A procedure to call the functions of the unit under test with


appropriate parameters

61
ONLINE COURSE REGISTRATION

1. Test for the admin module

• Testing admin login form-This form is used for log in of administrator of


the system. In this form we enter the username and password if both are
correct administration page will open otherwise if any of data is wrong it
will get redirected back to the login page and again ask the details.
• Report Generation: admin can generate report from the main database.

INTEGRATION TESTING

In the Integration testing we test various combination of the project module by


providing the input.

The primary objective is to test the module interfaces in order to confirm that no
errors are occurring when one module invokes the other module.

62
ONLINE COURSE REGISTRATION

6. SCREEN SHOTS

63
ONLINE COURSE REGISTRATION

Evaluation
Project URL: http://localhost/onlinecourse

Admin Login Page

Change Password

64
ONLINE COURSE REGISTRATION

Add/Manage Session

Add/Manage Semester

65
ONLINE COURSE REGISTRATION

Add/Manage Department

Add/Manage Course

66
ONLINE COURSE REGISTRATION

Student Registration

Manage Student

67
ONLINE COURSE REGISTRATION

Student Enroll History

Student Logs

68
ONLINE COURSE REGISTRATION

News

Student Login Page

69
ONLINE COURSE REGISTRATION

Change Password

STUDENT PINCODE VERIFICATION

Course Enroll

70
ONLINE COURSE REGISTRATION

Enroll History

71
ONLINE COURSE REGISTRATION

My Profile

72
ONLINE COURSE REGISTRATION

7. SYSTEM SECURITY

73
ONLINE COURSE REGISTRATION

INTRODUCTION

The protection of computer based resources that includes hardware, software, data,
procedures and people against unauthorized use or natural
Disaster is known as System Security. System Security can be divided into four
related issues:
 Security
 Integrity
 Privacy
 Confidentiality

SYSTEM SECURITY refers to the technical innovations and


procedures applied to the hardware and operation systems to protect against
deliberate or accidental damage from a defined threat.

DATA SECURITY is the protection of data from loss, disclosure,


modification and destruction.

SYSTEM INTEGRITY refers to the power functioning of hardware


and programs, appropriate physical security and safety against external
threats such as eavesdropping and wiretapping.

PRIVACY defines the rights of the user or organizations to determine


what information they are willing to share with or accept from others and
how the organization can be protected against unwelcome, unfair or
excessive dissemination of information about it.

CONFIDENTIALITY is a special status given to sensitive information in a


database to minimize the possible invasion of privacy. It is an attribute of
information that characterizes its need for protection

SECURITY IN SOFTWARE

System security refers to various validations on data in form of checks and controls
to avoid the system from failing. It is always important to ensure that only valid
data is entered and only valid operations are performed on the system. The system
employees two types of checks and controls:

74
ONLINE COURSE REGISTRATION

CLIENT SIDE VALIDATION

Various client side validations are used to ensure on the client side that only valid
data is entered. Client side validation saves server time and load to handle invalid
data. Some checks imposed are:
JavaScript in used to ensure those required fields are filled with suitable data only.
Maximum lengths of the fields of the forms are appropriately defined.
Forms cannot be submitted without filling up the mandatory data so that manual
mistakes of submitting empty fields that are mandatory can be sorted out at the
client side to save the server time and load.
Tab-indexes are set according to the need and taking into account the ease of user
while working with the system.

SERVER SIDE VALIDATION

Some checks cannot be applied at client side. Server side checks are necessary to
save the system from failing and intimating the user that some invalid operation
has been performed or the performed operation is restricted. Some of the server
side checks imposed is:
A primary key value cannot be duplicated. Any attempt to duplicate the primary
value results into a message intimating the user about those values through the
forms using foreign key can be updated only of the existing foreign key values.
User is intimating through appropriate messages about the successful operations or
exceptions occurring at server side.
Various Access Control Mechanisms have been built so that one user may not
agitate upon another. Access permissions to various types of users are controlled
according to the organizational structure. Only permitted users can log on to the
system and can have access according to their category. User- name, passwords
and permissions are controlled o the server side.
Using server side validation, constraints on several restricted operations are
imposed.

75
ONLINE COURSE REGISTRATION

SYSTEM IMPLEMENTATION

Implementation is the process of converting a new or revised system design into


operational one. There are three types of Implementation:
Implementation of a computer system to replace a manual system. The problems
encountered are converting files, training users, and verifying printouts for
integrity.
Implementation of new computer system to replace an existing one. This is usually
a difficult conversion. If not properly planned there can be many problems.
Implementation of a modified application to replace an existing one using the same
computer. This type of conversion is relatively easy to handle, provided there are
no major changes in the files.
Implementation in Generic tool project is done in all modules. In the first module
User level identification is done. In this module every user is identified whether
they are genuine one or not to access the database and also generates the session for
the user. Illegal use of any form is strictly avoided.
In the Table creation module, the tables are created with user specified fields and
user can create many tables at a time. They may specify conditions, constraints and
calculations in creation of tables. The Generic codes maintain the user
requirements throughout the project.
In Updating module user can update or delete or Insert the new record into the
database. This is very important module in Generic code project. User has to
specify the field value in the form then the Generic tool automatically gives whole
filed values for that particular record.

76
ONLINE COURSE REGISTRATION

8. CONCLUSION

77
ONLINE COURSE REGISTRATION

Conclusion:
This Application provides a computerized version of Online Course Registration
which will benefit the schools, educational camps, corporate training programs,
and online training programs.

The Application was designed in such a way that future changes can be
done easily. The following conclusions can be deduced from the development of
the project.

• Automation of the entire system improves the productivity.


• It provides a friendly graphical user interface which proves to be
better when compared to the existing system.
• It gives appropriate access to the authorized users depending on their
permissions.
• It effectively overcomes the delay in communications.
• Updating of information becomes so easier.
• System security, data security and reliability are the striking features.
• The System has adequate scope for modification in future if it is
necessary.

78
ONLINE COURSE REGISTRATION

9. BIBLIOGRAPHY

79
ONLINE COURSE REGISTRATION

References
For PHP
• https://www.w3schools.com/php/default.asp
• https://www.sitepoint.com/php/
• https://www.php.net/

For MYSQL
• https://www.mysql.com/
• http://www.mysqltutorial.org

For XAMPP

• https://www.apachefriends.org/download.html

80

You might also like