Lakshya Jangir 2
Lakshya Jangir 2
Project Report
On
“STUDENT RESULT MANAGEMENT SYSTEM”
UDAY KARDWAL
JYOTI SONI
LAKSHYA JANGIR
RONAK SONI
1|Page
Acknowledgement
It is pleasure to acknowledge many people who knowingly and unwittingly helped me, to complete
my project. First of all let me praise God all the blessings, which carried me through all these
years.
A project is a type of activity in which we have to develop a working model for a particular
problem. To achieve this, first of all we have to study it well. It kind of stuff is not possible without
the help of a senior person or an expert who already worked in the same direction. We are thankful
to all the faculties of C.S. department, HOD sir and all the college management, our project guide
for the guidance he provided us and encouraged us to work on this project. It was not possible for
us to prepare this project without their guidance and immense help.
I was able to work for such a good organization and excel in the work entrusted upon me. I am
grateful to all my friends and well-wishes for providing feedback and support whenever required.
Parents made us endure such time with their unfailing humor and warm wishes.
2|Page
Index
S.NO. PARTICULARS PAGE NO.
1 Acknowledgement 3
2 Certificate 4
3. Project Profile 5
3 Table of Content 6
4 Introduction 7
5 Software Model 7
6 Software Requirement Specification 8
7 System Requirement Specification 9
8. Coding 10
9 Design Time Form 24
10 Project Testing 30
11 Conclusion 30
12 Bibliography 31
3|Page
Self Certificate
This is to certify, that practical project of “BCA FINAL YEAR” named
“STUDENT RESULT MANAGEMENT SYSTEM” has been
successfully completed by “LAKSHYA JANGIR” student of BCA
FINAL YEAR During the year 2023-24, in the partial fulfillment for the
award of BCA FINAL YEAR, offered by the MAHARAJA GANGA
SINGH UNIVERSITY, BIKANER.
LAKSHYA JANGIR
BCA FINAL
(MGSU)
4|Page
Project Profile
Application XAMPP
Software Exposure
❖ Backend NOTEPAD
❖ Hardware Requirement
5|Page
Table of Content
1. Introduction
2.Software model
3.Software Requirement Specifications
3.1 Introduction
3.1.1 Purpose
3.1.2 Scope
3.1.3 Definitions, Acronyms and Abbreviations
3.1.4 References
3.1.5 Technologies to be used
3.1.6 Overview
3.2 Overall Description
3.2.1 Use case model survey
3.2.2 Database document
3.2.3 Assumptions and Dependencies
3.3 Specification Requirements
3.4 Concerns / Queries / Double if any:
4. System Requirement Specification H/W & S/W requirement
5. Coding
6. Designing
6|Page
1. INTRODUCTION
Simple Quiz is a mini project which is developed for the partial fulfillment of BCA SECOND
YEAR. This is demo project which provides an online platform to play a Quiz.
1. Displaying the Indian Flag
2. Showing complete flag.
2 SOFTWARE MODEL
We have use the waterfall Model to develop our software.
Analysis and
System Specific
Design
Integration and
System
Testing Operation
7 | PMaintenance
age
This model consists of five distinct phases:-
3) Coding and Unit testing:-In the coding and testing phase the designers are translated in
software domain. Detailed documentation from the design phase can significantly reduce the
coding effort. Testing at this phase focuses on making sure that any errors are identified and that
the software meets its required specification.
4) Integration and System Testing: - In the integration and system testing phase at the
program unit are integration and tested to ensure that the complete system meet software
requirement. After this stage the software is delivered to the customer.
8|Page
3. SOFTWARE REQUIREMENT SPECIFICATION
3.1 Introduction
3.1.1 Purpose
SRS provides feedback to the customer. An SRS is the customer’s assurance that the
development organization understands the issues of problems to be solved and the software
behavior necessary to address those problems. The SRS should be written in natural language.
The simple act of writing down software requirement in a well designed formal organizes
information, places, and borders around the problem, solidifies ideas and helps break down the
problem into its components parts in an orderly as a product validation check.
3.1.2 Scope
Small –scales Offices
Definitions Acronyms and Abbreviations
9|Page
3.1.4 References
3.1.6 Overview
The rest of the SRS contain the description of survey, database document for designing
database, detail of software requirement (which is sufficient to enable designer to design a
system satisfy to those requirement, and testers to test that the system satisfies those
requirements, supporting information, any specific project related queries will be answered.
• The admission table will contain the details like students registration no., personal detail,
academic qualification and other details etc.
• The password table will contain the detail of admin password to open the program and
maintain detail of students.
10 | P a g e
4. SYSTEM REQUIREMENT SPECIFICATIONS
11 | P a g e
CODING
CSS:
HomePage:
body {
font-size: 16px;
font-family: 'Roboto', sans-serif;
background-color: #222629;
color: white;
margin: 0;
}
hr {
border-top: 1px solid white;
}
.container {
padding: 0 5%;
}
.title {
display: flex;
font-size: 3em;
justify-content: center;
align-items: center;
height: 80px;
}
12 | P a g e
.main{
}
.main span {
font-size: 20px;
}
.main p {
font-size: 16px;
line-height: 2;
}
.info {
display: grid;
grid-gap: 2%;
grid-template-columns: 1fr 1fr 1fr 1fr;
}
.info span {
color: #86c232;
font-size: 20px;
}
.footer {
display: grid;
grid-template-columns: 1fr 1fr;
line-height: 2;
margin-top: 100px;
}
.footer a{
color: white;
display: block;
}
.footer span {
font-size: 20px;
}
/* navigation bar */
ul{
list-style-type: none;
margin: 30px 0;
padding: 0;
display: flex;
overflow: hidden;
justify-content: space-evenly;
border-style: solid;
border-width: 1px 0 1px 0;
13 | P a g e
}
li a,.dropbtn{
display: inline-block;
text-decoration: none;
color: white;
height: 40px;
display: flex;
align-items: center;
padding: 5px 50px;
}
li a:hover, .dropdown:hover {
background-color: #61892f
}
li.dropdown {
display: inline-block;
}
.dropdown-content{
display: none;
position: absolute;
background-color: #474b4f;
}
.dropdown-content a {
color: white;
text-decoration: none;
display: flex;
align-items: center;
.dropdown:hover .dropdown-content {
display: block;
}
/* image slider */
.slider {
text-align: center;
}
.slider img {
width: 50%;
}
14 | P a g e
Form:
input,select,option{
width: 100%;
padding: 12px 20px;
margin: 10px 0;
box-sizing: border-box;
display: block;
}
input[type=text],input[type=password],select{
background-color: #474b4f;
color: white;
border: none;
font-size: 100%;
letter-spacing: 0.2em;
}
input[type=submit]{
background-color: #474b4f;
color: white;
border: none;
transition-duration: 0.4s;
cursor: pointer;
font-size: 16px;
input[type=submit]:hover{
background-color: #86c232;
color: white
}
fieldset{
font-size: 20px;
border-radius: 10px;
border-width: 5px;
border-style: solid;
padding: 20px;
margin: 0 15%;
}
.error {
color: red;
margin: 30px 0 0 30vh;
}
15 | P a g e
Login:
body{
margin: 0;
background-color: #222629;
color: white;
font-family: 'Roboto', sans-serif;
}
.title{
font-size: 3em;
text-align: center;
margin-top: 10px;
}
.main{
display: grid;
grid-template-rows: 80vh;
grid-template-columns: 1fr 1fr;
align-items: center;
}
.login,.search{
padding: 20px;
}
/* form */
input,select{
width: 100%;
padding: 12px 20px;
margin: 10px 0;
box-sizing: border-box;
display: block;
}
input[type=text],input[type=password],select{
background-color: #474b4f;
color: white;
border: none;
font-size: 100%;
letter-spacing: 0.2em;
16 | P a g e
}
input[type=submit]{
background-color: #474b4f;
color: white;
border: none;
transition-duration: 0.4s;
cursor: pointer;
font-size: 16px;
input[type=submit]:hover{
background-color: #86c232;
color: white
}
fieldset{
font-size: 20px;
border-radius: 10px;
border-width: 5px;
border-style: solid;
}
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Index Page</title>
<link rel="stylesheet" href="css/login.css">
<link rel="stylesheet" href="./font-awesome-4.7.0/css/font-awesome.css">
<link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet">
</head>
<body>
<div class="title">
<span>Student Result Management System</span>
</div>
<div class="main">
<div class="login">
<form action="" method="post" name="login">
<fieldset>
<legend class="heading">Admin Login</legend>
<input type="text" name="userid" placeholder="Email" autocomplete="off">
<input type="password" name="password" placeholder="Password" autocomplete="off">
17 | P a g e
<input type="submit" value="Login">
</fieldset>
</form>
</div>
<div class="search">
<form action="./student.php" method="get">
<fieldset>
<legend class="heading">For Students</legend>
<?php
include('init.php');
</body>
</html>
18 | P a g e
Student:
body{
margin: 0;
font-family: 'Roboto', sans-serif;
}
.container {
margin: 5% 10%;
}
.title {
font-size: 50px;
text-align: center;
.details{
font-size: 20px;
letter-spacing: 0.1em;
}
.main{
font-size: 18px;
display: grid;
grid-template-columns: 1fr 1fr;
padding: 20px 25%;
}
.button{
text-align: center;
}
.main p{
text-align: center;
}
.main p:nth-child(1) {
font-weight: bold;
}
.result p{
font-size: 20px;
}
.error {
19 | P a g e
color: red;
margin: 30px 0 0 30vh;
}
/* hide buttom */
@media print {
.button {
display: none;
}
}
Manage:
/*table*/
.main{
display: grid;
justify-content: center;
padding: 30px;
}
.main table{
margin: 50px auto;
}
.main table, th, td {
border-collapse: collapse;
text-align: left;
table-layout: fixed;
padding: 8px 30px;
width: 50%;
}
.main th{
color: #61c232;
}
.main tr:hover {
background-color: #474b4f;
}
th, td {
border-bottom: 1px solid #ddd;
}
20 | P a g e
PHP:
Session:
<?php
include('init.php');
session_start();
$db = mysqli_select_db($conn,'srms');
$user_check = $_SESSION['login_user'];
$login_session = $row['userid'];
if(!isset($_SESSION['login_user'])){
header("Location:login.php");
}
?>
Login:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Index Page</title>
<link rel="stylesheet" href="css/login.css">
<link rel="stylesheet" href="./font-awesome-4.7.0/css/font-awesome.css">
<link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet">
</head>
<body>
<div class="title">
<span>Student Result Management System</span>
</div>
21 | P a g e
<div class="main">
<div class="login">
<form action="" method="post" name="login">
<fieldset>
<legend class="heading">Admin Login</legend>
<input type="text" name="userid" placeholder="Email" autocomplete="off">
<input type="password" name="password" placeholder="Password" autocomplete="off">
<input type="submit" value="Login">
</fieldset>
</form>
</div>
<div class="search">
<form action="./student.php" method="get">
<fieldset>
<legend class="heading">For Students</legend>
<?php
include('init.php');
</body>
</html>
<?php
include("init.php");
session_start();
if (isset($_POST["userid"],$_POST["password"]))
{
22 | P a g e
$username=$_POST["userid"];
$password=$_POST["password"];
$sql = "SELECT userid FROM admin_login WHERE userid='$username' and password = '$password'";
$result=mysqli_query($conn,$sql);
// $row=mysqli_fetch_array($result);
$count=mysqli_num_rows($result);
if($count==1) {
$_SESSION['login_user']=$username;
header("Location: dashboard.php");
}else {
echo '<script language="javascript">';
echo 'alert("Invalid Username or Password")';
echo '</script>';
}
}
?>
Logout:
<?php
session_start();
if(session_destroy()) {
header("Location: login.php");
echo '<script language="javascript">';
echo 'alert("Logout successful")';
echo '</script>';
}
?>
Student:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
23 | P a g e
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="./css/student.css">
<title>Result</title>
</head>
<body>
<?php
include("init.php");
if(!isset($_GET['class']))
$class=null;
else
$class=$_GET['class'];
$rn=$_GET['rn'];
// validation
if (empty($class) or empty($rn) or preg_match("/[a-z]/i",$rn)) {
if(empty($class))
echo '<p class="error">Please select your class</p>';
if(empty($rn))
echo '<p class="error">Please enter your roll number</p>';
if(preg_match("/[a-z]/i",$rn))
echo '<p class="error">Please enter valid roll number</p>';
exit();
}
24 | P a g e
echo "no result";
exit();
}
?>
<div class="container">
<div class="details">
<span>Name:</span> <?php echo $name ?> <br>
<span>Class:</span> <?php echo $class; ?> <br>
<span>Roll No:</span> <?php echo $rn; ?> <br>
</div>
<div class="main">
<div class="s1">
<p>Subjects</p>
<p>Paper 1</p>
<p>Paper 2</p>
<p>Paper 3</p>
<p>Paper 4</p>
<p>Paper 5</p>
</div>
<div class="s2">
<p>Marks</p>
<?php echo '<p>'.$p1.'</p>';?>
<?php echo '<p>'.$p2.'</p>';?>
<?php echo '<p>'.$p3.'</p>';?>
<?php echo '<p>'.$p4.'</p>';?>
<?php echo '<p>'.$p5.'</p>';?>
</div>
</div>
<div class="result">
<?php echo '<p>Total Marks: '.$mark.'</p>';?>
<?php echo '<p>Percentage: '.$percentage.'%</p>';?>
</div>
<div class="button">
<button onclick="window.print()">Print Result</button>
</div>
</div>
</body>
</html>
25 | P a g e
Dashboard:
<?php
include("init.php");
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="./css/home.css">
<link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet">
<link rel="stylesheet" href="./css/font-awesome-4.7.0/css/font-awesome.css">
<link rel="stylesheet" href="normalize.css">
<title>Dashboard</title>
<style>
.main{
border-radius: 10px;
border-width: 5px;
border-style: solid;
padding: 20px;
margin: 7% 20% 0 20%;
}
</style>
</head>
<body>
<div class="title">
<a href="dashboard.php"><img src="./images/logo1.png" alt="" class="logo"></a>
<span class="heading">Dashboard</span>
<a href="logout.php" style="color: white"><span class="fa fa-sign-out fa-2x">Logout</span></a>
</div>
<div class="nav">
<ul>
<li class="dropdown" onclick="toggleDisplay('1')">
<a href="" class="dropbtn">Classes  
26 | P a g e
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="1">
<a href="add_classes.php">Add Class</a>
<a href="manage_classes.php">Manage Class</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('2')">
<a href="#" class="dropbtn">Students  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="2">
<a href="add_students.php">Add Students</a>
<a href="manage_students.php">Manage Students</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('3')">
<a href="#" class="dropbtn">Results  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="3">
<a href="add_results.php">Add Results</a>
<a href="manage_results.php">Manage Results</a>
</div>
</li>
</ul>
</div>
<div class="main">
<?php
echo '<p>Number of classes:'.$no_of_classes[0].'</p>';
echo '<p>Number of students:'.$no_of_students[0].'</p>';
echo '<p>Number of results:'.$no_of_result[0].'</p>';
?>
</div>
<div class="footer">
<!-- <span>Designed & Coded By Jibin Thomas</span> -->
</div>
</body>
</html>
<?php
include('session.php');
?>
27 | P a g e
Add:
1. Class:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="./css/home.css">
<link rel="stylesheet" href="./css/form.css">
<link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet">
<link rel="stylesheet" href="./css/font-awesome-4.7.0/css/font-awesome.css">
<title>Add Class</title>
</head>
<body>
<div class="title">
<a href="dashboard.php"><img src="./images/logo1.png" alt="" class="logo"></a>
<span class="heading">Dashboard</span>
<a href="logout.php" style="color: white"><span class="fa fa-sign-out fa-2x">Logout</span></a>
</div>
<div class="nav">
<ul>
<li class="dropdown" onclick="toggleDisplay('1')">
<a href="" class="dropbtn">Classes  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="1">
<a href="add_classes.php">Add Class</a>
<a href="manage_classes.php">Manage Class</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('2')">
<a href="#" class="dropbtn">Students  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="2">
<a href="add_students.php">Add Students</a>
<a href="manage_students.php">Manage Students</a>
28 | P a g e
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('3')">
<a href="#" class="dropbtn">Results  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="3">
<a href="add_results.php">Add Results</a>
<a href="manage_results.php">Manage Results</a>
</div>
</li>
</ul>
</div>
<div class="main">
<form action="" method="post">
<fieldset>
<legend>Add Class</legend>
<input type="text" name="class_name" placeholder="Class Name">
<input type="text" name="class_id" placeholder="Class ID">
<input type="submit" value="Submit">
</fieldset>
</form>
</div>
<div class="footer">
<!-- <span>Designed & Coded By Jibin Thomas</span> -->
</div>
</body>
</html>
<?php
include('init.php');
include('session.php');
if (isset($_POST['class_name'],$_POST['class_id'])) {
$name=$_POST["class_name"];
$id=$_POST["class_id"];
// validation
if (empty($name) or empty($id) or preg_match("/[a-z]/i",$id)) {
if(empty($name))
echo '<p class="error">Please enter class</p>';
if(empty($id))
echo '<p class="error">Please enter class id</p>';
29 | P a g e
if(preg_match("/[a-z]/i",$id))
echo '<p class="error">Please enter valid class id</p>';
exit();
}
if (!$result) {
echo '<script language="javascript">';
echo 'alert("Invalid class name or class id")';
echo '</script>';
} else{
echo '<script language="javascript">';
echo 'alert("Successful)';
echo '</script>';
}
}
?>
2. Student:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="./css/home.css">
<link rel="stylesheet" type="text/css" href="./css/form.css" media="all">
<link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet">
<link rel="stylesheet" href="./css/font-awesome-4.7.0/css/font-awesome.css">
<title>Add Students</title>
</head>
<body>
<div class="title">
<a href="dashboard.php"><img src="./images/logo1.png" alt="" class="logo"></a>
<span class="heading">Dashboard</span>
<a href="logout.php" style="color: white"><span class="fa fa-sign-out fa-2x">Logout</span></a>
</div>
<div class="nav">
30 | P a g e
<ul>
<li class="dropdown" onclick="toggleDisplay('1')">
<a href="" class="dropbtn">Classes  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="1">
<a href="add_classes.php">Add Class</a>
<a href="manage_classes.php">Manage Class</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('2')">
<a href="#" class="dropbtn">Students  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="2">
<a href="add_students.php">Add Students</a>
<a href="manage_students.php">Manage Students</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('3')">
<a href="#" class="dropbtn">Results  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="3">
<a href="add_results.php">Add Results</a>
<a href="manage_results.php">Manage Results</a>
</div>
</li>
</ul>
</div>
<div class="main">
<form action="" method="post">
<fieldset>
<legend>Add Student</legend>
<input type="text" name="student_name" placeholder="Student Name">
<input type="text" name="roll_no" placeholder="Roll No">
<?php
include('init.php');
include('session.php');
31 | P a g e
$display=$row['name'];
echo '<option value="'.$display.'">'.$display.'</option>';
}
echo'</select>'
?>
<input type="submit" value="Submit">
</fieldset>
</form>
</div>
<div class="footer">
<!-- <span>© Designed & Coded By Jibin Thomas</span> -->
</div>
</body>
</html>
<?php
if(isset($_POST['student_name'],$_POST['roll_no'])) {
$name=$_POST['student_name'];
$rno=$_POST['roll_no'];
if(!isset($_POST['class_name']))
$class_name=null;
else
$class_name=$_POST['class_name'];
// validation
if (empty($name) or empty($rno) or empty($class_name) or preg_match("/[a-z]/i",$rno) or
!preg_match("/^[a-zA-Z ]*$/",$name)) {
if(empty($name))
echo '<p class="error">Please enter name</p>';
if(empty($class_name))
echo '<p class="error">Please select your class</p>';
if(empty($rno))
echo '<p class="error">Please enter your roll number</p>';
if(preg_match("/[a-z]/i",$rno))
echo '<p class="error">Please enter valid roll number</p>';
if (!preg_match("/^[a-zA-Z ]*$/",$name)) {
echo '<p class="error">No numbers or symbols allowed in name</p>';
}
exit();
}
$sql = "INSERT INTO `students` (`name`, `rno`, `class_name`) VALUES ('$name', '$rno',
'$class_name')";
32 | P a g e
$result=mysqli_query($conn,$sql);
if (!$result) {
echo '<script language="javascript">';
echo 'alert("Invalid Details")';
echo '</script>';
}
else{
echo '<script language="javascript">';
echo 'alert("Successful")';
echo '</script>';
}
}
?>
3. Result:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="./css/home.css">
<link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet">
<link rel="stylesheet" href="./css/font-awesome-4.7.0/css/font-awesome.css">
<link rel="stylesheet" href="./css/form.css">
<title>Dashboard</title>
</head>
<body>
<div class="title">
<a href="dashboard.php"><img src="./images/logo1.png" alt="" class="logo"></a>
<span class="heading">Dashboard</span>
<a href="logout.php" style="color: white"><span class="fa fa-sign-out fa-2x">Logout</span></a>
</div>
<div class="nav">
<ul>
<li class="dropdown" onclick="toggleDisplay('1')">
<a href="" class="dropbtn">Classes  
<span class="fa fa-angle-down"></span>
</a>
33 | P a g e
<div class="dropdown-content" id="1">
<a href="add_classes.php">Add Class</a>
<a href="manage_classes.php">Manage Class</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('2')">
<a href="#" class="dropbtn">Students  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="2">
<a href="add_students.php">Add Students</a>
<a href="manage_students.php">Manage Students</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('3')">
<a href="#" class="dropbtn">Results  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="3">
<a href="add_results.php">Add Results</a>
<a href="manage_results.php">Manage Results</a>
</div>
</li>
</ul>
</div>
<div class="main">
<form action="" method="post">
<fieldset>
<legend>Enter Marks</legend>
<?php
include("init.php");
include("session.php");
while($row = mysqli_fetch_array($class_result)) {
$display=$row['name'];
echo '<option value="'.$display.'">'.$display.'</option>';
}
34 | P a g e
echo'</select>';
?>
</body>
</html>
<?php
if(isset($_POST['rno'],$_POST['p1'],$_POST['p2'],$_POST['p3'],$_POST['p4'],$_POST['p5']))
{
$rno=$_POST['rno'];
if(!isset($_POST['class_name']))
$class_name=null;
else
$class_name=$_POST['class_name'];
$p1=(int)$_POST['p1'];
$p2=(int)$_POST['p2'];
$p3=(int)$_POST['p3'];
$p4=(int)$_POST['p4'];
$p5=(int)$_POST['p5'];
$marks=$p1+$p2+$p3+$p4+$p5;
$percentage=$marks/5;
// validation
if (empty($class_name) or empty($rno) or $p1>100 or $p2>100 or $p3>100 or $p4>100 or $p5>100 or
$p1<0 or $p2<0 or $p3<0 or $p4<0 or $p5<0 ) {
if(empty($class_name))
echo '<p class="error">Please select class</p>';
if(empty($rno))
echo '<p class="error">Please enter roll number</p>';
if(preg_match("/[a-z]/i",$rno))
echo '<p class="error">Please enter valid roll number</p>';
if(preg_match("/[a-z]/i",$marks))
echo '<p class="error">Please enter valid marks</p>';
35 | P a g e
if($p1>100 or $p2>100 or $p3>100 or $p4>100 or $p5>100 or $p1<0 or $p2<0 or $p3<0 or $p4<0 or
$p5<0)
echo '<p class="error">Please enter valid marks</p>';
exit();
}
$sql="INSERT INTO `result` (`name`, `rno`, `class`, `p1`, `p2`, `p3`, `p4`, `p5`, `marks`, `percentage`)
VALUES ('$display', '$rno', '$class_name', '$p1', '$p2', '$p3', '$p4', '$p5', '$marks', '$percentage')";
$sql=mysqli_query($conn,$sql);
if (!$sql) {
echo '<script language="javascript">';
echo 'alert("Invalid Details")';
echo '</script>';
}
else{
echo '<script language="javascript">';
echo 'alert("Successful")';
echo '</script>';
}
}
?>
Manage:
1. Class:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="css/home.css">
<link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet">
<link rel="stylesheet" href="./css/font-awesome-4.7.0/css/font-awesome.css">
36 | P a g e
<link rel="stylesheet" type='text/css' href="css/manage.css">
<title>Dashboard</title>
</head>
<body>
<div class="title">
<a href="dashboard.php"><img src="./images/logo1.png" alt="" class="logo"></a>
<span class="heading">Dashboard</span>
<a href="logout.php" style="color: white"><span class="fa fa-sign-out fa-2x">Logout</span></a>
</div>
<div class="nav">
<ul>
<li class="dropdown" onclick="toggleDisplay('1')">
<a href="" class="dropbtn">Classes  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="1">
<a href="add_classes.php">Add Class</a>
<a href="manage_classes.php">Manage Class</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('2')">
<a href="#" class="dropbtn">Students  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="2">
<a href="add_students.php">Add Students</a>
<a href="manage_students.php">Manage Students</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('3')">
<a href="#" class="dropbtn">Results  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="3">
<a href="add_results.php">Add Results</a>
<a href="manage_results.php">Manage Results</a>
</div>
</li>
</ul>
</div>
<div class="main">
<?php
37 | P a g e
include('init.php');
include('session.php');
$db = mysqli_select_db($conn,'srms');
if (mysqli_num_rows($result) > 0) {
echo "<table>
<caption>Manage Classes</caption>
<tr>
<th>ID</th>
<th>NAME</th>
</tr>";
while($row = mysqli_fetch_array($result))
{
echo "<tr>";
echo "<td>" . $row['id'] . "</td>";
echo "<td>" . $row['name'] . "</td>";
echo "</tr>";
echo "</table>";
} else {
echo "0 results";
}
?>
</div>
</body>
</html>
2. Student:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
38 | P a g e
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="css/home.css">
<link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet">
<link rel="stylesheet" href="./css/font-awesome-4.7.0/css/font-awesome.css">
<link rel="stylesheet" type='text/css' href="css/manage.css">
<title>Dashboard</title>
</head>
<body>
<div class="title">
<a href="dashboard.php"><img src="./images/logo1.png" alt="" class="logo"></a>
<span class="heading">Dashboard</span>
<a href="logout.php" style="color: white"><span class="fa fa-sign-out fa-2x">Logout</span></a>
</div>
<div class="nav">
<ul>
<li class="dropdown" onclick="toggleDisplay('1')">
<a href="" class="dropbtn">Classes  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="1">
<a href="add_classes.php">Add Class</a>
<a href="manage_classes.php">Manage Class</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('2')">
<a href="#" class="dropbtn">Students  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="2">
<a href="add_students.php">Add Students</a>
<a href="manage_students.php">Manage Students</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('3')">
<a href="#" class="dropbtn">Results  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="3">
<a href="add_results.php">Add Results</a>
<a href="manage_results.php">Manage Results</a>
</div>
</li>
</ul>
39 | P a g e
</div>
<div class="main">
<?php
include('init.php');
include('session.php');
$db = mysqli_select_db($conn,'srms');
if (mysqli_num_rows($result) > 0) {
echo "<table>
<caption>Manage Classes</caption>
<tr>
<th>ID</th>
<th>NAME</th>
</tr>";
while($row = mysqli_fetch_array($result))
{
echo "<tr>";
echo "<td>" . $row['id'] . "</td>";
echo "<td>" . $row['name'] . "</td>";
echo "</tr>";
echo "</table>";
} else {
echo "0 results";
}
?>
</div>
</body>
</html>
40 | P a g e
3. Result:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="./css/home.css">
<link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet">
<link rel="stylesheet" href="./css/font-awesome-4.7.0/css/font-awesome.css">
<link rel="stylesheet" href="./css/form.css">
<title>Dashboard</title>
</head>
<body>
<div class="title">
<a href="dashboard.php"><img src="./images/logo1.png" alt="" class="logo"></a>
<span class="heading">Dashboard</span>
<a href="logout.php" style="color: white"><span class="fa fa-sign-out fa-2x">Logout</span></a>
</div>
<div class="nav">
<ul>
<li class="dropdown" onclick="toggleDisplay('1')">
<a href="" class="dropbtn">Classes  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="1">
<a href="add_classes.php">Add Class</a>
<a href="manage_classes.php">Manage Class</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('2')">
<a href="#" class="dropbtn">Students  
<span class="fa fa-angle-down"></span>
</a>
<div class="dropdown-content" id="2">
<a href="add_students.php">Add Students</a>
<a href="manage_students.php">Manage Students</a>
</div>
</li>
<li class="dropdown" onclick="toggleDisplay('3')">
<a href="#" class="dropbtn">Results  
<span class="fa fa-angle-down"></span>
41 | P a g e
</a>
<div class="dropdown-content" id="3">
<a href="add_results.php">Add Results</a>
<a href="manage_results.php">Manage Results</a>
</div>
</li>
</ul>
</div>
<div class="main">
<br><br>
<form action="" method="post">
<fieldset>
<legend>Delete Result</legend>
<?php
include('init.php');
include('session.php');
<?php
$class_result=mysqli_query($conn,"SELECT `name` FROM `class`");
echo '<select name="class">';
echo '<option selected disabled>Select Class</option>';
while($row = mysqli_fetch_array($class_result)){
$display=$row['name'];
echo '<option value="'.$display.'">'.$display.'</option>';
}
42 | P a g e
echo'</select>'
?>
</body>
</html>
<?php
if(isset($_POST['class_name'],$_POST['rno'])) {
$class_name=$_POST['class_name'];
$rno=$_POST['rno'];
echo $class_name;
echo $rno;
$delete_sql=mysqli_query($conn,"DELETE from `result` where `rno`='$rno' and `class`='$class_name'");
if(!$delete_sql){
echo '<script language="javascript">';
echo 'alert("Not available")';
echo '</script>';
} else {
echo '<script language="javascript">';
echo 'alert("Deleted")';
echo '</script>';
}
}
if(isset($_POST['rn'],$_POST['p1'],$_POST['p2'],$_POST['p3'],$_POST['p4'],$_POST['p5'],$_POST['class'
])) {
$rno=$_POST['rn'];
$class_name=$_POST['class'];
$p1=(int)$_POST['p1'];
$p2=(int)$_POST['p2'];
43 | P a g e
$p3=(int)$_POST['p3'];
$p4=(int)$_POST['p4'];
$p5=(int)$_POST['p5'];
$marks=$p1+$p2+$p3+$p4+$p5;
$percentage=$marks/5;
if(!$update_sql){
echo '<script language="javascript">';
echo 'alert("Invalid Details")';
echo '</script>';
} else {
echo '<script language="javascript">';
echo 'alert("Updated")';
echo '</script>';
}
}
?>
Database:
-- phpMyAdmin SQL Dump
-- version 4.7.6
-- https://www.phpmyadmin.net/
--
-- Host: localhost
-- Generation Time: Jan 10, 2018 at 04:35 PM
-- Server version: 10.1.29-MariaDB
-- PHP Version: 7.2.0
44 | P a g e
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8mb4 */;
--
-- Database: `srms`
--
-- --------------------------------------------------------
--
-- Table structure for table `admin_login`
--
--
-- Dumping data for table `admin_login`
--
-- --------------------------------------------------------
--
-- Table structure for table `class`
--
-- --------------------------------------------------------
--
-- Table structure for table `result`
--
45 | P a g e
`class` varchar(30) NOT NULL,
`p1` int(3) NOT NULL,
`p2` int(3) NOT NULL,
`p3` int(3) NOT NULL,
`p4` int(3) NOT NULL,
`p5` int(3) NOT NULL,
`marks` int(3) NOT NULL,
`percentage` float NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
-- --------------------------------------------------------
--
-- Table structure for table `students`
--
--
-- Indexes for dumped tables
--
--
-- Indexes for table `admin_login`
--
ALTER TABLE `admin_login`
ADD PRIMARY KEY (`userid`);
--
-- Indexes for table `class`
--
ALTER TABLE `class`
ADD PRIMARY KEY (`name`),
ADD UNIQUE KEY `id` (`id`);
--
-- Indexes for table `result`
--
ALTER TABLE `result`
ADD KEY `class` (`class`),
ADD KEY `name` (`name`,`rno`);
46 | P a g e
--
-- Indexes for table `students`
--
ALTER TABLE `students`
ADD PRIMARY KEY (`name`,`rno`),
ADD KEY `class_name` (`class_name`);
--
-- Constraints for dumped tables
--
--
-- Constraints for table `result`
--
ALTER TABLE `result`
ADD CONSTRAINT `result_ibfk_1` FOREIGN KEY (`class`) REFERENCES `class` (`name`),
ADD CONSTRAINT `result_ibfk_2` FOREIGN KEY (`name`,`rno`) REFERENCES `students` (`name`,
`rno`);
--
-- Constraints for table `students`
--
ALTER TABLE `students`
ADD CONSTRAINT `students_ibfk_1` FOREIGN KEY (`class_name`) REFERENCES `class` (`name`);
COMMIT;
47 | P a g e
DESIGN
Home-page:
48 | P a g e
49 | P a g e
Admin:
50 | P a g e
Add Student:
51 | P a g e
Add Result:
Result:
52 | P a g e
Update or Delete Result:
53 | P a g e
Database:
54 | P a g e
55 | P a g e
E-R diagram:
56 | P a g e
PROJECT TESTING
• COMPILATION TEST:
• It was a good idea to do our stress testing early on, because it gave us time to fix some of
the unexpected deadlocks and stability problems that only occurred when components
were exposed to very high transaction volumes.
• EXECUTION TEST:
• This program was successfully loaded and executed. Because of good programming
there were no execution error.
• OUTPUT TEST:
• The successful output screens are placed in the output screens section.
57 | P a g e
BIBLIOGRAPHY
SOFTWARE ENGINEERING
By Roger.S. Pressman
Java
By Balaguruswamy
SAD
By M. AWAD
58 | P a g e
59 | P a g e