Professional Documents
Culture Documents
SUBMITTED BY
Neha Lalmani Yadav
CERTIFICATE
This is to certify that Miss Neha Lalmani Yadav Roll No 63 has successfully completed
the PROJECT titled “University Management System” of Sem V for partial fulfillment
of Bachelor of Science in Computer Science of University of Mumbai in academic year
2022 -2023 under the guidance of
INDEX
2 OVERVIEW 5 - 10
2.1 ABSTRACT
2.2 UNDERTAKING
2.4 OBJECTIVE
2.4 INTRODUCTION
2.5 REQUIREMENT SPECIFICATION
3 GANTT CHART 11
9 REFERENCES 130
9.1 WEBSITES
9.2 BOOKS
1. Acknowledgement
I would like to convey my special thanks to the Management and all the staff of
the college for providing the required infrastructure and resources to enable the
completion and enrichment of my project.
Finally I thank all my fellow friends who have directly or indirectly helped me
in completing my project.
2. Overview
2.1. Abstract
University management system project is a web-based solution for colleges, universities, and
schools. It was created for the university and its affiliated institutions to conduct, monitor,
and analyze complicated activities such as student admission, examinations, and much more.
It is a program that manages the complete student life cycle up to degree completion.
UMS helps make important tasks like admission, results processing, registration, and fee
management more efficient, so they can be done faster. All users, including students, college
and university personnel, paper valuers, setters, and moderators, are given a role-based
login/password to complete their tasks. Each student has access to an online tool through the
university’s examination management system to complete the following Student Lifecycle
tasks. This is available to all students.
2.2. Undertaking
I Miss Neha Yadav Student of TYBSC – Computer Science hereby declare that
I have Completed the project on “University Management System ''.
The Information Submitted is True and Original to the best of Knowledge.
SIGNATURE OF STUDENT
Neha Yadav
2.3. Objective
The goal of this research was to create a university management project system
that would aid in the maintenance of university records. Creating strategies for
efficient management and handling of a task in every university. The university
management system project includes features that allow for quick access to donor
records gathered across the country.
2.4. Introduction
The university management system improves the institution’s work organization and
decreases the amount of paperwork that wastes time. If you
wish to enroll in a university, you must first register in the system and obtain all of th
e essential information.
The goal of this research was to create a university management project system that
would aid in the maintenance of university records. Creating strategies for efficient
management and handling of a task in every university. The university management
system project includes features that allow for quick access to donor records
gathered across the country.
No User Friendly
Manual Operation
No Security Features
HIGHER education is characterized by “the tension between the offered quality
and the drive to provide affordable higher education to more and more people
Also, SOA and Grid solutions, as with many other computing technologies, require
certain hardware and software infrastructure to be setup before they can be used for
lab assignments. This demands specialized technical skills from both professors
and students to set up the experimental environment. These tasks often distract
students from the real goals of the course since they are focusing their effort on
peripheral tasks more related to system administration than to the course topics.
In order to solve these problems, a new system has been created, that attempts to
operate the whole procedure considering the database integration approach.
Student Side:
● Browser
3. Gantt Chart
Figure 4.2.2: Activity Diagram(Student and Faculty Side) for University Management
System
University Management System Data Flow Diagram - represents the flow of data and their
transformations within the university management system. The input, processing, and output are used to
represent and define the overall university management system. The data flow diagram comes with three
levels which will elaborate the system's concept from a single node up to specific.
University Management System Use Case Diagram - A university management system use case diagram
is a visual representation of how the user interacts with the system. It depicts the system’s numerous use
cases and different sorts of users. The circles or ellipses are used to depict the use cases. The use case
diagram for the university management system comes with several diagrams that describe the function of
various use cases from the general use case. It uses the labels <> and <>to know the structure and behavior
of the system at the same time.
5. Code Implementation
Main CSS
html {
color: #222;
font-size: 1em;
line-height: 1.4;
}
/*
* Remove text-shadow in selection highlight:
* https://twitter.com/miketaylr/status/12228805301
*
* These selection rule sets have to be separate.
* Customize the background color to match your design.
*/
::-moz-selection {
background: #b3d4fc;
text-shadow: none;
}
::selection {
background: #b3d4fc;
text-shadow: none;
}
/*
* A better looking default horizontal rule
*/
hr {
display: block;
height: 1px;
border: 0;
border-top: 1px solid #ccc;
margin: 1em 0;
padding: 0;
}
/*
* Remove the gap between audio, canvas, iframes,
* images, videos and the bottom of their containers:
* https://github.com/h5bp/html5-boilerplate/issues/440
*/
audio,
canvas,
iframe,
img,
svg,
video {
vertical-align: middle;
}
/*
* Remove default fieldset styles.
*/
fieldset {
border: 0;
margin: 0;
padding: 0;
}
/*
* Allow only vertical resizing of textareas.
*/
textarea {
resize: vertical;
}
/* ==========================================================================
Browser Upgrade Prompt
========================================================================== */
.browserupgrade {
margin: 0.2em 0;
background: #ccc;
color: #000;
padding: 0.2em 0;
}
/* ==========================================================================
Author's custom styles
========================================================================== */
a{
text-decoration:none;
}
.fix{
overflow:hidden;
}
body{
font-family:roboto !important;
background:url(../img/ptrn.png) repeat fixed;
}
.container {
/* width:1000px; */
display:block;
margin:0 auto;
background:#FFFFFF;
.head {
float:left;
width:400px;
.logo {
width:100px;
margin-left:20px;
float:left;
}
.logo img{
width:75px;
height:80px;
}
.uniname {
width:280px;
float:left;
padding-top: 10px;
}
.uniname h2{
font-size:22px;
font-weight:normal;
color:#E3E3E5;
margin-top: 20;
padding: 0;
margin: 0;
}
.uniname h5{
font-size: 13px;
font-style: italic;
margin: 0;
color: #ffffff;
font-weight: normal;
}
.dateshow p{
color: #fff;
text-align: right;
margin: 0;
margin-top: 5px;
margin-right: 20px;
padding: 0;
font-size: 14px;
font-style: italic;
}
.menu {
width:600px;
float:right;
}
.menu ul {
color: #e3e3e5;
list-style: outside none none;
margin: 20px 20px 0 0;
padding: 0;
}
.menu>ul>li{
float:right;
display:block;
}
.menu>ul>li a {
color: #e3e3e5;
font-size: 16px;
padding: 3px 6px;
}
.menu>ul>li a:hover {
color:#0BB69F;
}
.sidebar {
float:left;
padding:10px;
width:180px;
background:#2A2B3C;
}
.sidebar ul{
margin-top:30;
padding:0;
list-style:none;
}
.sidebar>ul>li{
font-size:18px;
background:#0CC2AA;
color: #e3e3e5;
padding:5px 5px;
border-radius:5px;
}
.spcl{
}
.sidebar ul ul li {
padding-left:15px;
padding-top:6px;
padding-bottom:6px;
margin:5px 0 0 1px;
}
.sidebar ul ul li:hover{
background:#3a3b4c;
}
.sidebar ul ul li a {
color: #e3e3e5;
padding: 8px;
}
.maincontent{
min-height:580px;
}
.content {
float: right;
padding: 10px 170px;
width: 780px;
}
.cpright{
position: relative;
bottom: 0;
.msg{
}
.msg h3{
text-align: center;
}
.access {
.loginform p{
text-align: center;
}
.loginform a{
color:#0ea17f;
}
.loginform input[type="text"], .loginform input[type="password"] {
}
#st_form{
width:370px;
margin:0 auto;
}
.st_reg h2{
margin:0;
margin-bottom:20px;
padding:10px 0;
background:#1abc9c;
font-weight:normal;
font-family:consolas, arial;
text-align:center;
color:#fff;
}
.st_reg th, td {
padding: 8px;
}
.st_reg select{
width:80px;
padding:2px;
border: 1px solid #1abc9c;
border-radius: 5px;
}
.birthday{
width:48px;
padding:2px;
border: 1px solid #1abc9c;
border-radius: 5px;
}
.birthyear{
width:70px;
padding:2px;
border: 1px solid #1abc9c;
border-radius: 5px;
}
.st_reg input[type="text"], .st_reg input[type="password"], .st_reg input[type="email"] {
padding: 2px 5px;
margin-bottom: 4px 0;
width: 96%;
display: block;
font-size: 16px;
border-radius: 5px;
border: 1px solid #1abc9c;
-webkit-transition: 0.3s linear;
-moz-transition: 0.3s linear;
-o-transition: 0.3s linear;
transition: 0.3s linear;
}
.st_reg input[type="text"]:focus, .st_reg input[type="password"]:focus, .st_reg input[type="email"]:focus {
outline: none;
box-shadow: 0 0 1px 1px #1abc9c;
}
.st_reg input[type="submit"] {
background: #1abc9c;
padding: 8px;
font-size: 16px;
display: block;
width: 100%;
border: none;
color: #fff;
border-radius: 5px;
}
.st_reg input[type="submit"]:hover {
background: #1bc6a4;
}
/*Table desing for view info*/
/*page desing*/
table.tab_one{
width:100%;
}
table.tab_one th{
background:#1abc9c;
padding:10px;
font-weight:bold;
text-align:left;
}
table.tab_one td{
border:1px solid #ddd;
padding:8px;
}
table.tab_one td a{
text-decoration:none;
}
table.tab_one tr:nth-child(odd){
background:#ddd;
}
table.tab_one tr:nth-child(even){
background:#ecf0f1;
}
/*edit button*/
.editbtn {
background-color: #01C3AA;
border: none;
border-radius:5px;
color: white;
padding: 5px 18px;
text-align: center;
text-decoration: none;
display: inline-block;
font-size: 15px;
margin: 2px 1px;
cursor: pointer;
}
/*admin Page*/
.admin_profile{
min-height:450px;
padding:20px;
}
.section{
width:48.3%;
float:left;
margin:10px;
}
.section h3{
text-align:center;
}
/*
table.tab_two{
width:100%;
border-collapse:collapse;
}
table.tab_two tr {
border:1px solid #ddd;
border-collapse:collapse;
}
table.tab_two td{
text-align:center;
padding:20px;
}
table.tab_two td a{
padding: 5px;
color: #00C2A9;
}
table.tab_one tr:hover{
background-color:#f5f5f5;
}
*/
.section ul{
margin:0;
padding:0;
border:1px solid #ddd;
list-style:none;
}
.section ul li{
border:1px solid #ddd;
}
.section ul li a{
display:block;
padding:20px;
color:#006f61;
text-align:center;
text-decoration:none;
}
.section ul li a:hover{
background:#ddd;
}
/*search student*/
.all_student{
min-height:450px;
}
.search_st{
background:#9b59b6;
height:45px;
}
.search{
float:right;
}
.hdinfo{
float:left;
width:500px;
}
.hdinfo h3{
font-size:18px;
color:#fff;
padding:10px;
margin:0;
font-weight:normal;
}
.search input[type=text] {
line-height: normal;
padding: 5px;
margin: 3px;
border-radius:5px;
width:125px;
}
.search input[type=submit] {
padding:6px;
margin-right:15px;
border:none;
background:#E8E8FF;
border-radius:5px;
}
}
table.att_tab tr,td,th{
border:2px solid #ddd;
border-collapse:collapse;
padding:8px;
}
.attn select{
width:176px;
}
.attmanage{
float:left;
width:499px;
}
.attmanage form{
padding-left:110px;
}
input[type=radio]:checked ~ .atd {
border: 5px solid #0DFF92;
}
input[type=radio]:checked ~ .atd::before{
background: #0DFF92;
}
/*
* Hide visually and from screen readers
*/
/*stick a div*/
#sticker {
background:#2A2B3C;
}
.stick {
position:fixed;
top:0px;
}
#stickerside {
background:#2A2B3C;
}
.stickside {
position:fixed;
left:175px;
}
.hidden {
display: none !important;
}
/*
* Hide only visually, but have it available for screen readers:
* http://snook.ca/archives/html_and_css/hiding-content-for-accessibility
*/
.visuallyhidden {
border: 0;
clip: rect(0 0 0 0);
height: 1px;
margin: -1px;
overflow: hidden;
padding: 0;
position: absolute;
width: 1px;
}
/*
* Extends the .visuallyhidden class to allow the element
* to be focusable when navigated to via the keyboard:
* https://www.drupal.org/node/897638
*/
.visuallyhidden.focusable:active,
.visuallyhidden.focusable:focus {
clip: auto;
height: auto;
margin: 0;
overflow: visible;
position: static;
width: auto;
}
/*
* Hide visually and from screen readers, but maintain layout
*/
.invisible {
visibility: hidden;
}
/*
* Clearfix: contain floats
*
* For modern browsers
* 1. The space content is one way to avoid an Opera bug when the
* `contenteditable` attribute is included anywhere else in the document.
* Otherwise it causes space to appear at the top and bottom of elements
* that receive the `clearfix` class.
* 2. The use of `table` rather than `block` is only necessary if using
* `:before` to contain the top-margins of child elements.
*/
.clearfix:before,
.clearfix:after {
content: " "; /* 1 */
display: table; /* 2 */
}
.clearfix:after {
clear: both;
}
/* ==========================================================================
EXAMPLE Media Queries for Responsive Design.
These examples override the primary ('mobile first') styles.
Modify as content requires.
========================================================================== */
@media print,
(-webkit-min-device-pixel-ratio: 1.25),
(min-resolution: 1.25dppx),
(min-resolution: 120dpi) {
/* Style adjustments for high resolution devices */
}
/* ==========================================================================
Print styles.
Inlined to avoid the additional HTTP request:
http://www.phpied.com/delay-loading-your-print-css/
========================================================================== */
@media print {
*,
*:before,
*:after,
*:first-letter,
*:first-line {
background: transparent !important;
color: #000 !important; /* Black prints faster:
http://www.sanbeiji.com/archives/953 */
box-shadow: none !important;
text-shadow: none !important;
}
a,
a:visited {
text-decoration: underline;
}
a[href]:after {
content: " (" attr(href) ")";
}
abbr[title]:after {
content: " (" attr(title) ")";
}
/*
* Don't show links that are fragment identifiers,
* or use the `javascript:` pseudo protocol
*/
a[href^="#"]:after,
a[href^="javascript:"]:after {
content: "";
}
pre,
blockquote {
border: 1px solid #999;
page-break-inside: avoid;
}
/*
* Printing Tables:
* http://css-discuss.incutio.com/wiki/Printing_Tables
*/
thead {
display: table-header-group;
}
tr,
img {
page-break-inside: avoid;
}
img {
max-width: 100% !important;
}
p,
h2,
h3 {
orphans: 3;
widows: 3;
}
h2,
h3 {
page-break-after: avoid;
}
}
Normalize CSS
html {
font-family: sans-serif; /* 1 */
-ms-text-size-adjust: 100%; /* 2 */
-webkit-text-size-adjust: 100%; /* 2 */
}
/**
* Remove default margin.
*/
body {
margin: 0;
}
/**
* Correct `block` display not defined for any HTML5 element in IE 8/9.
* Correct `block` display not defined for `details` or `summary` in IE 10/11
* and Firefox.
* Correct `block` display not defined for `main` in IE 11.
*/
article,
aside,
details,
figcaption,
figure,
footer,
header,
hgroup,
main,
menu,
nav,
section,
summary {
display: block;
}
/**
* 1. Correct `inline-block` display not defined in IE 8/9.
* 2. Normalize vertical alignment of `progress` in Chrome, Firefox, and Opera.
*/
audio,
canvas,
progress,
video {
display: inline-block; /* 1 */
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:33
University Management System
vertical-align: baseline; /* 2 */
}
/**
* Prevent modern browsers from displaying `audio` without controls.
* Remove excess height in iOS 5 devices.
*/
audio:not([controls]) {
display: none;
height: 0;
}
/**
* Address `[hidden]` styling not present in IE 8/9/10.
* Hide the `template` element in IE 8/9/10/11, Safari, and Firefox < 22.
*/
[hidden],
template {
display: none;
}
/* Links
========================================================================== */
/**
* Remove the gray background color from active links in IE 10.
*/
a{
background-color: transparent;
}
/**
* Improve readability of focused elements when they are also in an
* active/hover state.
*/
a:active,
a:hover {
outline: 0;
}
/* Text-level semantics
========================================================================== */
/**
* Address styling not present in IE 8/9/10/11, Safari, and Chrome.
*/
abbr[title] {
/**
* Address style set to `bolder` in Firefox 4+, Safari, and Chrome.
*/
b,
strong {
font-weight: bold;
}
/**
* Address styling not present in Safari and Chrome.
*/
dfn {
font-style: italic;
}
/**
* Address variable `h1` font-size and margin within `section` and `article`
* contexts in Firefox 4+, Safari, and Chrome.
*/
h1 {
font-size: 2em;
margin: 0.67em 0;
}
/**
* Address styling not present in IE 8/9.
*/
mark {
background: #ff0;
color: #000;
}
/**
* Address inconsistent and variable font size in all browsers.
*/
small {
font-size: 80%;
}
/**
* Prevent `sub` and `sup` affecting `line-height` in all browsers.
*/
sub,
sup {
font-size: 75%;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sup {
top: -0.5em;
}
sub {
bottom: -0.25em;
}
/* Embedded content
========================================================================== */
/**
* Remove border when inside `a` element in IE 8/9/10.
*/
img {
border: 0;
}
/**
* Correct overflow not hidden in IE 9/10/11.
*/
svg:not(:root) {
overflow: hidden;
}
/* Grouping content
========================================================================== */
/**
* Address margin not present in IE 8/9 and Safari.
*/
figure {
margin: 1em 40px;
}
/**
* Address differences between Firefox and other browsers.
*/
hr {
box-sizing: content-box;
height: 0;
/**
* Contain overflow in all browsers.
*/
pre {
overflow: auto;
}
/**
* Address odd `em`-unit font size rendering in all browsers.
*/
code,
kbd,
pre,
samp {
font-family: monospace, monospace;
font-size: 1em;
}
/* Forms
========================================================================== */
/**
* Known limitation: by default, Chrome and Safari on OS X allow very limited
* styling of `select`, unless a `border` property is set.
*/
/**
* 1. Correct color not being inherited.
* Known issue: affects color of disabled elements.
* 2. Correct font properties not being inherited.
* 3. Address margins set differently in Firefox 4+, Safari, and Chrome.
*/
button,
input,
optgroup,
select,
textarea {
color: inherit; /* 1 */
font: inherit; /* 2 */
margin: 0; /* 3 */
}
/**
* Address `overflow` set to `hidden` in IE 8/9/10/11.
*/
button {
overflow: visible;
}
/**
* Address inconsistent `text-transform` inheritance for `button` and `select`.
* All other form control elements do not inherit `text-transform` values.
* Correct `button` style inheritance in Firefox, IE 8/9/10/11, and Opera.
* Correct `select` style inheritance in Firefox.
*/
button,
select {
text-transform: none;
}
/**
* 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`
* and `video` controls.
* 2. Correct inability to style clickable `input` types in iOS.
* 3. Improve usability and consistency of cursor style between image-type
* `input` and others.
*/
button,
html input[type="button"], /* 1 */
input[type="reset"],
input[type="submit"] {
-webkit-appearance: button; /* 2 */
cursor: pointer; /* 3 */
}
/**
* Re-set default cursor for disabled elements.
*/
button[disabled],
html input[disabled] {
cursor: default;
}
/**
* Remove inner padding and border in Firefox 4+.
*/
button::-moz-focus-inner,
input::-moz-focus-inner {
border: 0;
padding: 0;
}
/**
* Address Firefox 4+ setting `line-height` on `input` using `!important` in
* the UA stylesheet.
*/
input {
line-height: normal;
}
/**
* It's recommended that you don't attempt to style these elements.
* Firefox's implementation doesn't respect box-sizing, padding, or width.
*
* 1. Address box sizing set to `content-box` in IE 8/9/10.
* 2. Remove excess padding in IE 8/9/10.
*/
input[type="checkbox"],
input[type="radio"] {
box-sizing: border-box; /* 1 */
padding: 0; /* 2 */
}
/**
* Fix the cursor style for Chrome's increment/decrement buttons. For certain
* `font-size` values of the `input`, it causes the cursor style of the
* decrement button to change from `default` to `text`.
*/
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
height: auto;
}
/**
* 1. Address `appearance` set to `searchfield` in Safari and Chrome.
* 2. Address `box-sizing` set to `border-box` in Safari and Chrome.
*/
input[type="search"] {
-webkit-appearance: textfield; /* 1 */
box-sizing: content-box; /* 2 */
}
/**
* Remove inner padding and search cancel button in Safari and Chrome on OS X.
* Safari (but not Chrome) clips the cancel button when the search input has
* padding (and `textfield` appearance).
*/
input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
/**
* Define consistent border, margin, and padding.
*/
fieldset {
border: 1px solid #c0c0c0;
margin: 0 2px;
padding: 0.35em 0.625em 0.75em;
}
/**
* 1. Correct `color` not being inherited in IE 8/9/10/11.
* 2. Remove padding so people aren't caught out if they zero out fieldsets.
*/
legend {
border: 0; /* 1 */
padding: 0; /* 2 */
}
/**
* Remove default vertical scrollbar in IE 8/9/10/11.
*/
textarea {
overflow: auto;
}
/**
* Don't inherit the `font-weight` (applied by a rule above).
* NOTE: the default cannot safely be changed in Chrome and Safari on OS X.
*/
optgroup {
font-weight: bold;
}
/* Tables
========================================================================== */
/**
* Remove most spacing between table cells.
*/
table {
border-collapse: collapse;
border-spacing: 0;
}
td,
th {
padding: 0;
}
Plugins JS
(function() {
var method;
var noop = function () {};
var methods = [
'assert', 'clear', 'count', 'debug', 'dir', 'dirxml', 'error',
'exception', 'group', 'groupCollapsed', 'groupEnd', 'info', 'log',
'markTimeline', 'profile', 'profileEnd', 'table', 'time', 'timeEnd',
'timeline', 'timelineEnd', 'timeStamp', 'trace', 'warn'
];
var length = methods.length;
var console = (window.console = window.console || {});
while (length--) {
method = methods[length];
Configuration PHP
<?php
class databaseConnection{
public function __construct(){
global $conn;
$conn = new mysqli("localhost", "root", "" , "uni");
//check error
if(!$conn){
die("Database cannot established connection properly: " . $conn->connect_error());
}
}
}
?>
Functions PHP
<?php
class login_registration_class{
public function __construct(){
$db = new databaseConnection();
}
$num = $query->num_rows;
$in_sql = "INSERT INTO st_info (st_id,name,password,email,bday,program,contact,gender,address)
VALUES ('$st_id','$st_name','$st_pass','$st_email','$bday','$st_dept','$st_contact','$st_gender','$st_add') ";
if($num == 0){
$conn->query($in_sql);
return true;
}else{
return false;
}
}
$count = $result->num_rows;
if($count == 1){
session_start();
$_SESSION['st_login'] = true;
$_SESSION['sid'] = $userdata['st_id'];
$_SESSION['sname'] = $userdata['name'];
//$_SESSION['login_msg'] = "Login Success";
return true;
}else{
return false;
}
unset($_SESSION['sname']);
unset($_SESSION['st_login']);
//session_destroy();
}
public function getsession(){
return @$_SESSION['st_login'];
}
/**
---------------------------------
All functions for faculty section
---------------------------------
**/
public function fct_registration($name,$uname, $pass,$email, $bday,$gender,$edu,$contact,$address){
global $conn;
$fct = $conn->query("select id from faculty where username='$uname' ");
$count = $fct->num_rows;
if($count == 0){
$sql = "insert into faculty(name,username,password,email,birthday,gender,education,contact,address)
values('$name','$uname','$pass','$email','$bday','$gender','$edu','$contact','$address')";
$result = $conn->query($sql);
return true;
}else{
return false;
}
}
//get faculty
public function get_faculty_by_username($uname){
global $conn;
$sql = "select * from faculty where username='$uname'";
$result = $conn->query($sql);
return $result;
}
public function get_faculty(){
global $conn;
$sql = "select * from faculty order by id ASC";
$result = $conn->query($sql);
return $result;
}
//login for faculty
public function fct_login($uname, $pass){
global $conn;
$sql = "select id,username,name from faculty where username='$uname' and password='$pass' ";
$result = $conn->query($sql);
$count = $result->num_rows;
$fctinfo = $result->fetch_assoc();
if($count == 1){
session_start();
$_SESSION['fct_login'] = true;
$_SESSION['f_id'] = $fctinfo['id'];
$_SESSION['f_uname'] = $fctinfo['username'];
$_SESSION['f_name'] = $fctinfo['name'];
return true;
}else{
return false;
}
}
public function faculty_logout(){
$_SESSION['fct_login'] = false;
unset($_SESSION['f_id']);
unset($_SESSION['f_uname']);
unset($_SESSION['f_name']);
unset($_SESSION['fct_login']);
}
public function get_faculty_session(){
return @$_SESSION['fct_login'];
}
/*
**********************
----------------------
All functions for Admin
----------------------
**********************
*/
if($count == 1){
session_start();
$_SESSION['admin_login'] = true;
$_SESSION['admin_id'] = $admin_info['id'];
$_SESSION['admin_name'] = $admin_info['username'];
return true;
}else{
return false;
}
}
public function get_admin_session(){
return @$_SESSION['admin_login'];
}
//admin logout
public function admin_logout(){
$_SESSION['admin_login'] = false;
unset($_SESSION['admin_id']);
unset($_SESSION['admin_name']);
unset($_SESSION['admin_login']);
}
//delete student
public function delete_student($st_id){
global $conn;
$sql = "delete from st_info where st_id='$st_id' ";
$result = $conn->query($sql);
if($result){
return true;
}else{
return false;
}
}
//attendance system
$result = $conn->query($sql);
while($row = $result->fetch_assoc()){
$db_date = $row['at_date'];
if($cur_date == $db_date){
return false;
}
}
foreach($atten as $key =>$attn_value ){
if($attn_value == "present"){
$sql = "insert into attn(st_id,atten,at_date) values('$key','present','$cur_date')";
$att_res = $conn->query($sql);
}elseif($attn_value == "absent"){
$sql = "insert into attn(st_id,atten,at_date) values('$key','absent','$cur_date')";
$att_res = $conn->query($sql);
}
}
if($att_res){
return true;
}else{
return false;
}
}
public function delete_atn_student($at_id){
global $conn;
$res = $conn->query("delete from at_student where id = '$at_id' ");
return $res;
}
public function get_attn_date(){
global $conn;
$res = $conn->query("select distinct at_date from attn ");
return $res;
}
public function attn_all_student($date){
global $conn;
$res = $conn->query("select at_student.name, attn.*
from at_student
inner join attn
on at_student.st_id = attn.st_id
where at_date = '$date' ");
return $res;
}
public function update_attn($date,$atten){
global $conn;
foreach($atten as $key =>$attn_value ){
if($attn_value == "present"){
$sql = "update attn set atten='present' where st_id='$key' and at_date='$date' ";
$att_res = $conn->query($sql);
}elseif($attn_value == "absent"){
$sql = "update attn set atten='absent' where st_id='$key' and at_date='$date' ";
$att_res = $conn->query($sql);
}
}
if($att_res){
return true;
}else{
return false;
}
}
//grading system
public function add_marks($stid,$subject,$semester,$marks){
global $conn;
$qry = "select * from result where st_id='$stid' and sub='$subject' and semester='$semester' ";
$query = $conn->query($qry);
$count = $query->num_rows;
if($count>0){
return false;
}else{
$sql = "insert into result(st_id,marks,sub,semester) values('$stid','$marks','$subject','$semester')";
$result = $conn->query($sql);
return $result;
}
}
//show marks
public function show_marks($stid,$semester){
global $conn;
$result = $conn->query("select * from result where st_id='$stid' and semester='$semester' ");
$count = $result->num_rows;
if($count>0){
return $result;
}else{
return false;
}
}
//update student result
public function update_result($stid,$subject = array(),$semester){
global $conn;
foreach($subject as $key =>$mark ){
$sql = "update result set marks='$mark' where st_id='$stid' and semester='$semester' and sub='$key'
";
$result = $conn->query($sql);
}
if($result){
return true;
}else{
return false;
}
}
public function view_cgpa($stid){
global $conn;
$sql = "select * from result where st_id='$stid'";
$result = $conn->query($sql);
return $result;
}
//end class
};
?>
<!Doctype html>
<html class="no-js" lang="">
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<title><?php echo $pageTitle; ?></title>
<meta name="description" content="University Management system">
<meta name="author" content="Md Abul Kalam">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Place favicon.ico in the root directory -->
<?php } ?>
</ul>
</div>
</div>
</header>
<div class="info container fix">
<!Doctype html>
<html class="no-js" lang="">
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<title><?php echo $pageTitle; ?></title>
<meta name="description" content="University Management system">
<meta name="author" content="Md Abul Kalam">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Place favicon.ico in the root directory -->
<!--[if lt IE 8]>
<p class="browserupgrade">You are using an <strong>outdated</strong> browser. Please <a
href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
<![endif]-->
<?php } ?>
</ul>
</div>
</div>
</header>
<div class="info container fix">
Headertop PHP
<!Doctype html>
<html class="no-js" lang="">
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<title><?php echo $pageTitle; ?></title>
<meta name="description" content="University Management system">
<meta name="author" content="Md Abul Kalam">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Place favicon.ico in the root directory -->
<?php } ?>
</ul>
</div>
</div>
</header>
<div class="info container fix">
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
if(isset($_REQUEST['ar'])){
$stid = $_REQUEST['ar'];
$name = $_REQUEST['vn'];
}
?>
<?php
$pageTitle = "Student Result";
include "php/headertop_admin.php";
?>
<div class="all_student fix">
<?php
if($_SERVER['REQUEST_METHOD'] == 'POST'){
$subject = $_POST['subject'];
$semester = $_POST['semester'];
$marks = $_POST['marks'];
$res = $user->add_marks($stid,$subject,$semester,$marks);
if($res){
echo "<h3 style='color:green;margin:0;padding:0;text-align:center'>Marks successfully
inserted!</h3>";
}else{
echo "<p style='color:red;text-align:center'>Failed to insert data</p>";
}
}
</select>
</td>
</tr>
<tr>
<td>Select Semester: </td>
<td>
<select name="semester" id="">
<option value="1st">1st semester</option>
<option value="2nd">2nd semester</option>
<option value="3rd">3rd semester</option>
</select>
</td>
</tr>
<tr>
<td>Input marks: </td>
<td><input type="text" name="marks" placeholder="enter marks" required /></td>
</tr>
<tr>
<td><input type="submit" name="sub" value="Add marks" /></td>
<td><input type="reset" /></td>
</tr>
</table>
</form>
</table>
</div>
<div class="back fix">
<p style="text-align:center"><a href="st_result.php"><button class="editbtn">Back to
list</button></a></p>
</div>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
<?php
ob_start ();
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
?>
<?php
$pageTitle = "All Faculty details";
include "php/headertop_admin.php";
?>
<div class="all_student">
<div class="search_st">
<div class="hdinfo"><h3>All Registered Faculty List</h3></div>
</div>
<table class="tab_one">
<tr>
<th>SL</th>
<th>Name</th>
<th>Email</th>
<th>Contact</th>
<th>Education</th>
<th>Address</th>
<th>Birthday</th>
</tr>
<?php
$i=0;
$alluser =$user->get_faculty();
while($rows = $alluser->fetch_assoc()){
$i++;
?>
<tr>
<td><?php echo $i; ?></td>
<td><?php echo $rows['name'];?></td>
<td><?php echo $rows['email'];?></td>
<td><?php echo $rows['contact'];?></td>
<td><?php echo $rows['education'];?></td>
<td><?php echo $rows['address'];?></td>
<td><?php echo $rows['birthday'];?></td>
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:55
University Management System
</tr>
<?php } ?>
</table>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
<?php
ob_start ();
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
?>
<?php
$pageTitle = "All student details";
include "php/headertop_admin.php";
?>
<div class="all_student">
<div class="search_st">
<div class="hdinfo"><h3>All Registered Student List</h3></div>
<div class="search">
<form action="admin_search_student.php" method="GET">
<input type="text" name="src_student" placeholder="search student" />
<input type="submit" value="Search" />
</form>
</div>
</div>
<?php
if(isset($_REQUEST['res'])){
if($_REQUEST['res']==1){
echo "<h3 style='color:green;text-align:center;margin:0;padding:10px;'>Data deleted
successfully</h3>";
}
}
?>
<table class="tab_one">
<tr>
<th>SL</th>
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:56
University Management System
<th>Name</th>
<th>ID</th>
<th>Show Profile</th>
<th>Edit</th>
<th>Delete</th>
<th>Photo</th>
</tr>
<?php
$i=0;
$alluser = $user->get_all_student();
while($rows = $alluser->fetch_assoc()){
$i++;
?>
<tr>
<td><?php echo $i; ?></td>
<td><?php echo $rows['name'];?></td>
<td><?php echo $rows['st_id'];?></td>
<td><a href="admin_single_student.php?id=<?php echo $rows['st_id'];?>">View
Details</a></td>
<td><a href="admin_single_student_update.php?id=<?php echo $rows['st_id'];?>">Edit</a></td>
<td><a href="admin_delete_student.php?id=<?php echo $rows['st_id'];?>">Delete</a></td>
<td><img src="img/student/<?php echo $rows['img'];?>" width="50px" height="50px"
title="<?php echo $rows['name'];?>" /></td>
</tr>
<?php } ?>
</table>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(isset($_REQUEST['id'])){
$st_id = $_REQUEST['id'];
}
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
$delete =$user->delete_student($st_id);
if($delete){
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:57
University Management System
header('Location: admin_all_student.php?res=1');
exit();
}
?>
Admin logout
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$user->admin_logout();
header('Location: index.php');
exit();
?>
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
?>
<?php
$pageTitle = "All student details";
include "php/headertop_admin.php";
?>
<div class="search_result">
<table class="tab_one">
<?php
$key = $_GET['src_student'];
$min_length = 1;
if(strlen($key) >= $min_length){
$key = htmlspecialchars($key);
$src_result = $user->search($key);
$count = $src_result->num_rows;
if($count>0){
?>
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:58
University Management System
<tr>
<th>Name</th>
<th>ID</th>
<th>Show Profile</th>
<th>Edit</th>
<th>Delete</th>
<th>Photo</th>
</tr>
<?php
while($rows = $src_result->fetch_assoc()){
?>
<tr>
<td><?php echo $rows['name'];?></td>
<td><?php echo $rows['st_id'];?></td>
<td><a href="admin_single_student.php?id=<?php echo $rows['st_id'];?>">View
Details</a></td>
<td><a href="admin_single_student_update.php?id=<?php echo $rows['st_id'];?>">Edit</a></td>
<td><a href="admin_delete_student.php?id=<?php echo $rows['st_id'];?>">Delete</a></td>
<td><img src="img/student/<?php echo $rows['img'];?>" width="50px" height="50px"
title="<?php echo $rows['name'];?>" /></td>
</tr>
<?php } ?>
</table>
<?php
}else{
echo "<h2 style='font-size:45px;text-align:center;color:#ddd;'>Opps....No result found !</h2>";
}
}else{
echo "<h2 style='font-size:45px;text-align:center;color:#ddd;'>Opps....No result found !</h2>";
}
?>
<div class="back fix">
<p style="text-align:center"><a href="admin_all_student.php"><button class="editbtn">Back to
student list</button></a></p>
</div>
</div>
<?php include "php/footerbottom.php";?>
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(isset($_REQUEST['id'])){
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:59
University Management System
$st_id = $_REQUEST['id'];
}else{
header('Location: admin.php');
exit();
}
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
?>
<?php
$pageTitle = "Student Details";
include "php/headertop_admin.php";
?>
<script>
function PreviewImage(upname, prv_id) {
var oFReader = new FileReader();
oFReader.readAsDataURL(document.getElementsByName(upname)[0].files[0]);
</script>
<div class="profile">
<h3 style="font-size:18px;text-
align:center;background:#1abc9c;color:#fff;padding:10px;margin:0">Update Profile</h3>
<?php
$qry=$user->getuserbyid($st_id);
$pic=$qry->fetch_assoc();
$piclocation=$pic['img'];
if($_SERVER['REQUEST_METHOD'] == "POST"){
//code for img
function guid() {
if (function_exists('com_create_guid')) {
return com_create_guid();
} else {
mt_srand((double) microtime() * 10000); //optional for php 4.2.0 and up.
$charid = strtoupper(md5(uniqid(rand(), true)));
$hyphen = chr(45); // "-"
$uuid = chr(123)// "{"
. substr($charid, 0, 8) . $hyphen
. substr($charid, 8, 4) . $hyphen
. substr($charid, 12, 4) . $hyphen
. substr($charid, 16, 4) . $hyphen
. substr($charid, 20, 12)
. chr(125); // "}"
return $uuid;
}
}
if($_FILES["personal_image"]["name"])
{
$path_parts = pathinfo($_FILES["personal_image"]["name"]);
$ext = $path_parts['extension'];
$fileName = trim(guid(), '{}') . '.' . $ext;
}
else{
$fileName = $piclocation;
}
move_uploaded_file($_FILES['personal_image']['tmp_name'], "img/student/$fileName");
//end img
$st_name = $_POST['st_name'];
$st_email = $_POST['st_email'];
$st_dept = $_POST['st_dept'];
$st_contact = $_POST['st_contact'];
$st_gender = $_POST['st_gender'];
$st_add = $_POST['st_add'];
if(empty($st_name) or empty($st_email) or empty($st_contact) or empty($st_dept) or
empty($st_gender) or empty($st_add)){
echo "<p style='color:red;text-align:center'>Field must not be empty.</p>";
}else{
$update = $user-
>updateprofile($st_id,$st_name,$st_email,$st_dept,$st_gender,$st_contact,$st_add,$fileName);
if($update){
echo "<h4 style='color:green;text-align:center'>Information Updated
successfully</h4>";
}else{
echo "<h4 style='color:red;text-align:center;text-align:center'>Failed to update</h4>";
}
}
}
?>
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(isset($_REQUEST['id'])){
$st_id = $_REQUEST['id'];
}else{
header('Location: admin.php');
exit();
}
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
?>
<?php
$pageTitle = "Student Details";
include "php/headertop_admin.php";
?>
<div class="profile">
<p style="font-size:18px;text-
align:center;background:#1abc9c;color:#fff;padding:10px;margin:0"><?php $user->getusername($st_id); ?>
<i class="fa fa-check-circle" aria-hidden="true"></i></p>
<table class="tab_one">
<?php
$getuser = $user->getuserbyid($st_id);
while($row = $getuser->fetch_assoc()){
?>
<tr>
<td></td>
<?php if(empty($row['img'])){?>
<td><img src="img/default.png" style="height:180px; width:180px; border:1px #1ABC9C
solid;border-radius:90px" alt="" /></td>
<?php }else{ ?>
<td><img src="img/student/<?php echo $row['img']; ?>" style="height:180px; width:180px;
border:1px #1ABC9C solid;border-radius:90px" alt="" /></td>
<?php }?>
</tr>
<tr>
<td>Student ID: </td>
<td><?php echo $row['st_id']; ?></td>
</tr>
<tr>
<td>Name: </td>
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:63
University Management System
</div>
Att add
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:64
University Management System
$admin_name = $_SESSION['admin_name'];
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
?>
<?php
$pageTitle = "All student details";
include "php/headertop_admin.php";
?>
<div class="all_student fix">
<h3 style="text-align:center;color:#fff;margin:0;padding:5px;background:#1abc9c">Attendance
Management</h3>
<div class="fix" style="background:#ddd;padding:20px;">
<span style="float:left;"><button
style="background:#58A85D;border:none;color:#fff;padding:10px;"><a style="color:#fff;"
href="att_add.php">Add student</a></button></span>
<span style="float:right;"> <button
style="background:#58A85D;border:none;color:#fff;padding:10px;"><a style="color:#fff;"
href="class_att.php">Back</a></button></span>
</div>
<?php
if(isset($_POST['sub'])){
$name = $_POST['name'];
$stid = $_POST['stid'];
$add = $user->add_attn_student($name,$stid);
if($add){
echo "<h3 style='color:green;margin:0;padding:0;text-align:center'>Successfull!</h3>";
}else{
echo "<p style='color:red;text-align:center'>Failed</p>";
}
}
?>
<div style="margin-left:330px;padding-top:30px;">
<table>
<form action="" method="post">
<table>
<tr>
<td>Student Name: </td>
<td><input type="text" name="name" required/></td>
</tr>
<tr>
<td>Student Id: </td>
<td><input type="text" name="stid" required /></td>
</tr>
<tr>
<td><input type="submit" name="sub" value="Add student" /></td>
</form>
</div>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
Att del
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
if(isset($_REQUEST['dl'])){
$at_id = $_REQUEST['dl'];
}
$delete =$user->delete_atn_student($at_id);
if($delete){
header('Location: class_att.php?res=1');
exit();
}
?>
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
if(isset($_REQUEST['dt'])){
$date = $_REQUEST['dt'];
}
?>
<?php
$pageTitle = "All student details";
include "php/headertop_admin.php";
?>
<div class="all_student fix">
<h3 style="text-align:center;color:#fff;margin:0;padding:5px;background:#1abc9c">Attendance
Management</h3>
<div class="fix" style="background:#ddd;padding:20px;">
<span style="float:left;"><a style="color:#fff;" href="class_att.php"><button
style="background:#58A85D;border:none;color:#fff;padding:10px;">Take
Attendance</button></a></span>
<span style="float:right;"><a style="color:#fff;" href="att_view.php"> <button
style="background:#58A85D;border:none;color:#fff;padding:10px;">View
Attendance</button></a></span>
</div>
<p style="text-align:center;color:#34495e;margin:0;padding-top:8px;color:red;font-size:22px;">
<?php echo "Attendance of: ".$date;?>
</p>
<?php
if($_SERVER['REQUEST_METHOD'] == 'POST'){
$atten = $_POST['attn'];
$res = $user->update_attn($date,$atten);
if($res){
echo "<h3 style='color:green;margin:0;padding:0;text-align:center'>Attendance Updated
successfully!</h3>";
}else{
echo "<p style='color:red;text-align:center'>Failed to update data</p>";
}
}
?>
</tr>
<?php
$i=0;
$std = $user->attn_all_student($date);
//var_dump($std);
if($std){
while($rows = $std->fetch_assoc()){
$i++;
?>
<tr>
<td><?php echo $i;?></td>
<td><?php echo $rows['name'];?></td>
<td><?php echo $rows['st_id'];?></td>
<td>
<label style="color:red;font-size:20px"><input type="radio" name="attn[<?php echo
$rows['st_id'];?>]" value="absent" <?php if($rows['atten'] == "absent") echo "checked";?>/>Absent</label>
</table>
<center>
<span><input style="<text-align:right></text-
align:right>;background:#58A85D;border:none;color:#fff;padding:8px 100px;" type="submit"
name="submit" value="Update" /></span>
</center>
</form>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$fid = $_SESSION['f_id'];
$funame = $_SESSION['f_uname'];
$fname = $_SESSION['f_name'];
if(!$user->get_faculty_session()){
header('Location: facultylogin.php');
exit();
}
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:68
University Management System
if(isset($_REQUEST['dt'])){
$date = $_REQUEST['dt'];
}
?>
<?php
$pageTitle = "Attendance details";
include "php/headertop.php";
?>
<div class="all_student fix">
<h3 style="text-align:center;color:#fff;margin:0;padding:5px;background:#1abc9c">View Attendance
Details</h3>
<div class="fix" style="background:#ddd;padding:20px;">
<span style="float:left;"><a style="color:#fff;" href="class_att_fc.php"><button
style="background:#58A85D;border:none;color:#fff;padding:10px;">Take Attendance</button></a></span>
<span style="float:right;"><a style="color:#fff;" href="att_view_fc.php"> <button
style="background:#58A85D;border:none;color:#fff;padding:10px;">View Attendance</button></a></span>
</div>
<p style="text-align:center;color:#34495e;margin:0;padding-top:8px;color:red;font-size:22px;">
<?php echo "Attendance of: ".$date;?>
</p>
<?php
if($_SERVER['REQUEST_METHOD'] == 'POST'){
$atten = $_POST['attn'];
$res = $user->update_attn($date,$atten);
if($res){
echo "<h3 style='color:green;margin:0;padding:0;text-align:center'>Attendance Updated
successfully!</h3>";
}else{
echo "<p style='color:red;text-align:center'>Failed to update data</p>";
}
}
?>
</tr>
<?php
$i=0;
$std = $user->attn_all_student($date);
//var_dump($std);
if($std){
while($rows = $std->fetch_assoc()){
$i++;
?>
<tr>
<td><?php echo $i;?></td>
<td><?php echo $rows['name'];?></td>
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:69
University Management System
</table>
<span style="margin-left:360px;"><input style="<text-align:right></text-
align:right>;background:#58A85D;border:none;color:#fff;padding:8px 100px;" type="submit" name="submit"
value="Update" /></span>
</form>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
Att view
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
?>
<?php
$pageTitle = "All student details";
include "php/headertop_admin.php";
?>
<div class="all_student fix">
<h3 style="text-align:center;color:#fff;margin:0;padding:5px;background:#1abc9c">Attendance
Management</h3>
<div class="fix" style="background:#ddd;padding:20px;">
<span style="float:left;"><button
style="background:#58A85D;border:none;color:#fff;padding:10px;"><a style="color:#fff;"
href="att_add.php">Add student</a></button></span>
<span style="float:right;"> <button
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:70
University Management System
style="background:#58A85D;border:none;color:#fff;padding:10px;"><a style="color:#fff;"
href="class_att.php">Take Attendance</a></button></span>
</div>
</tr>
<?php
$i=0;
$get_date = $user->get_attn_date();
while($rows = $get_date->fetch_assoc()){
$i++;
?>
<tr>
<td><?php echo $i;?></td>
<td><?php echo $rows['at_date'];?></td>
<td><a href="att_single_view.php?dt=<?php echo $rows['at_date']; ?>">View
Attendance</a></td>
</tr>
<?php } ?>
</table>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
Att view fc
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$fid = $_SESSION['f_id'];
$funame = $_SESSION['f_uname'];
$fname = $_SESSION['f_name'];
if(!$user->get_faculty_session()){
header('Location: facultylogin.php');
exit();
}
?>
<?php
$pageTitle = "All student details";
include "php/headertop.php";
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:71
University Management System
?>
<div class="all_student fix">
<h3 style="text-align:center;color:#fff;margin:0;padding:5px;background:#1abc9c">View
Attendance</h3>
<div class="fix" style="background:#ddd;padding:20px;">
<span style="float:right;"> <button
style="background:#58A85D;border:none;color:#fff;padding:10px;"><a style="color:#fff;"
href="class_att_fc.php">Take Attendance</a></button></span>
</div>
</tr>
<?php
$i=0;
$get_date = $user->get_attn_date();
while($rows = $get_date->fetch_assoc()){
$i++;
?>
<tr>
<td><?php echo $i;?></td>
<td><?php echo $rows['at_date'];?></td>
<td><a href="att_single_view_fc.php?dt=<?php echo $rows['at_date']; ?>">View
Attendance</a></td>
</tr>
<?php } ?>
</table>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
Class att
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:72
University Management System
}
?>
<?php
$pageTitle = "All student details";
include "php/headertop_admin.php";
?>
<div class="all_student fix">
<h3 style="text-align:center;color:#fff;margin:0;padding:5px;background:#1abc9c">Attendance
Management</h3>
<div class="fix" style="background:#ddd;padding:20px;">
<span style="float:left;"><a style="color:#fff;" href="att_add.php"><button
style="background:#58A85D;border:none;color:#fff;padding:10px;">Add student</button></a></span>
<span style="float:right;"><a style="color:#fff;" href="att_view.php"> <button
style="background:#58A85D;border:none;color:#fff;padding:10px;">View
Attendance</button></a></span>
</div>
<?php
if(isset($_REQUEST['res'])){
echo "<h3 style='color:green;margin:0;padding:0;text-align:center'>Data deleted successfully
!</h3>";
}
?>
<?php
if($_SERVER['REQUEST_METHOD'] == 'POST'){
$cur_date = $_POST['attndate'];
$atten = $_POST['attn'];
$res = $user->insertattn($cur_date,$atten);
if($res){
echo "<h3 style='color:green;margin:0;padding:0;text-align:center'>Attendance data
successfully inserted!</h3>";
}else{
echo "<p style='color:red;text-align:center'>Failed to insert data</p>";
}
}
?>
</tr>
<?php
$i=0;
$alluser = $user->attn_student();
while($rows = $alluser->fetch_assoc()){
$i++;
?>
<tr>
<td><?php echo $i;?></td>
<td><?php echo $rows['name'];?></td>
<td><?php echo $rows['st_id'];?></td>
<td>
<label style="color:red;font-size:20px"><input type="radio" name="attn[<?php echo
$rows['st_id'];?>]" value="absent" checked/>Absent</label>
</table>
<center>
<span><input style="<text-align:right></text-
align:right>;background:#58A85D;border:none;color:#fff;padding:8px 100px;" type="submit"
name="submit" value="Submit" /></span> <br>
</center>
</form>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
Class att fc
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$fid = $_SESSION['f_id'];
$funame = $_SESSION['f_uname'];
$fname = $_SESSION['f_name'];
if(!$user->get_faculty_session()){
header('Location: facultylogin.php');
exit();
}
?>
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:74
University Management System
<?php
$pageTitle = "All student details";
include "php/headertop.php";
?>
<div class="all_student fix">
<h3 style="text-align:center;color:#fff;margin:0;padding:5px;background:#1abc9c"> Take
Attendance</h3>
<div class="fix" style="background:#ddd;padding:20px;">
<span style="text-align:center;"><a style="color:#fff;" href="att_view_fc.php"> <button
style="background:#58A85D;border:none;color:#fff;padding:10px;">View
Attendance</button></a></span>
</div>
<?php
if(isset($_REQUEST['res'])){
echo "<h3 style='color:green;margin:0;padding:0;text-align:center'>Data deleted successfully
!</h3>";
}
?>
<?php
if($_SERVER['REQUEST_METHOD'] == 'POST'){
$cur_date = $_POST['attndate'];
$atten = $_POST['attn'];
$res = $user->insertattn($cur_date,$atten);
if($res){
echo "<h3 style='color:green;margin:0;padding:0;text-align:center'>Attendance data
successfully inserted!</h3>";
}else{
echo "<p style='color:red;text-align:center'>Failed to insert data</p>";
}
}
?>
</tr>
<?php
$i=0;
$alluser = $user->attn_student();
while($rows = $alluser->fetch_assoc()){
$i++;
?>
<tr>
<td><?php echo $i;?></td>
<td><?php echo $rows['name'];?></td>
<td><?php echo $rows['st_id'];?></td>
<td>
<label style="color:red;font-size:20px"><input type="radio" name="attn[<?php echo
$rows['st_id'];?>]" value="absent" checked/>Absent</label>
</table>
<span style="margin-left:360px;"><input style="<text-align:right></text-
align:right>;background:#58A85D;border:none;color:#fff;padding:8px 100px;" type="submit"
name="submit" value="Submit" /></span>
</form>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
Faculty list
<?php
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
require('plugins/fpdf/fpdf.php');
require('plugins/fpdf/rotation.php');
$this->Text($x,$y,$txt);
$this->Rotate(0);
}
}
$pdf->Image('img/logo.png',10,9,17);
$pdf->Ln();
$pdf-> Cell(20);
$pdf->SetFont('Times','',14);
$pdf->Write(5, $iubat);
$pdf->Ln();
$pdf-> Cell(22);
$pdf->SetFont('Times','',10);
$pdf->Write(4,'Developed by Md Abul Kalam');
$pdf-> Cell(20);
$pdf->SetFont('Times','',8);
$pdf->Write(5,
'_______________________________________________________________________________________
___________________________________________');
$pdf->Ln();
$pdf->Ln();
$pdf-> Cell(85);
$pdf->SetFont('Times','U',10);
$pdf->Write(5, 'Faculty List');
$pdf->Ln();
$pdf->Ln(2);
$pdf-> Cell(5);
$pdf->SetFont('Times','B',8);
$pdf->Cell(8,6,'SL',1);
$pdf->Cell(40,6,'Faculty Name',1);
$pdf->Cell(40,6,'Contact',1);
$pdf->Cell(40,6,'Email',1);
$pdf->Cell(40,6,'Education',1);
$pdf->Ln();
$qry = $user->get_faculty();
$sl=1;
while($rec = $qry->fetch_assoc())
{
$pdf-> Cell(5);
$pdf->SetFont('Times','',8);
$pdf->Cell(8,20,$sl,1);
$pdf->Cell(40,20,$rec['name'],1);
$pdf->Cell(40,20,$rec['contact'],1);
$pdf->Cell(40,20,$rec['email'],1);
$pdf->Cell(40,20,$rec['education'],1);
$sl++;
$pdf->Ln();
}
$pdf->Ln();
$pdf->Ln();
$pdf->Output();
?>
Faculty login
<?php
ob_start ();
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
if($user->get_faculty_session()){
header('Location: class_att_fc.php');
exit();
}
?>
<?php
$pageTitle = "Faculty login";
include "header.php";
?>
<div class="loginform fix">
<div class="msg "><h3><i class="fa fa-user" aria-hidden="true"></i> Faculty login</h3></div>
<div class="access">
<?php
//php for faculty login
if($_SERVER['REQUEST_METHOD'] == "POST"){
$username = $_POST['user'];
$psw = $_POST['psw'];
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:78
University Management System
if(empty($username) or empty($psw)){
echo "<p style='color:red;text-align:center;'>Field must not be empty.</p>";
}else{
$psw = md5($psw);
$login = $user->fct_login($username, $psw);
if($login){
header('Location: class_att_fc.php');
}else{
echo "<p style='color:red;text-align:center'>Incorrect Username or password</p>";
}
}
}
?>
<?php
include "footer.php";
ob_end_flush() ;
?>
Faculty logout
<?php
ob_start();
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$user->faculty_logout();
header('Location: facultylogin.php');
exit();
ob_end_flush();
?>
Fct reg
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$BirthMonth = $_POST['BirthMonth'];
$BirthDay = $_POST['BirthDay'];
$BirthYear = $_POST['BirthYear'];
$bday = "{$BirthYear}-{$BirthMonth}-{$BirthDay}";
$st_gender = $_POST['gender'];
$degree = $_POST['degree'];
$subject = $_POST['subject'];
$inst = $_POST['inst'];
$edu = "{$degree} in {$subject} from {$inst}";
$st_contact = $_POST['st_contact'];
$st_add = $_POST['st_add'];
</p>
<form action="" method="post" id="st_form">
<table>
<tr>
<th>Name: </th>
<td><input type="text" name="st_name" placeholder="Full Name" required /></td>
</tr>
<tr>
<tr>
<th>Username: </th>
<td><input type="text" name="uname" placeholder="username" required /></td>
</tr>
<tr>
<th>Password: </th>
<td><input type="password" name="st_pass" placeholder="password" required /></td>
</tr>
<tr>
<th>E-mail: </th>
<td><input type="email" name="st_email" placeholder="example@email.com" required
/></td>
</tr>
<tr>
<th>Date of Birth: </th>
<td>
<fieldset>
<option value="02">Feb</option>
<option value="04">April</option>
<option value="05">May</option>
<option value="06">June</option>
<option value="07">July</option>
<option value="08">Aug</option>
<option value="09">Sep</option>
<option value="10">Oct</option>
<option value="11">Nov</option>
<option value="12" >Dec</option>
</label>
</select>
required=""></label>
</fieldset>
</td>
</tr>
<tr>
<th>Gender:</th>
<td><label><input type="radio" name="gender" value="Male" checked/> Male</label>
<label><input type="radio" name="gender" value="Female"/> Female</label>
</td>
</tr>
<tr>
<th>Education: </th>
<td>
<fieldset>
<select class="select-style" name="degree">
<option value="BSc">BSc</option>
<option value="MSc">MSc</option>
<option value="Phd" >Phd</option>
</select>
<label><input class="birthyear" name="subject" placeholder="Subject"
required=""></label>
<label><input class="birthyear" name="inst" placeholder="Institute" required=""></label>
</fieldset>
</td>
</tr>
<tr>
<th>Contact:</th>
<td><input type="text" name="st_contact" placeholder="phone" required /></td>
</tr>
<tr>
<th>Address:</th>
<td><input type="text" name="st_add" placeholder="Address" required /></td>
</tr>
<tr>
<td colspan="2"><input style="color:#ddd;background:#3498db" type="submit" name="sub"
value="Register" /></td>
</tr>
</table>
</form>
</div>
<?php
ob_start();
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$fid = $_SESSION['f_id'];
$funame = $_SESSION['f_uname'];
$fname = $_SESSION['f_name'];
if(!$user->get_faculty_session()){
header('Location: facultylogin.php');
exit();
}
?>
<?php
$pageTitle = "Student Profile";
include "php/headertop.php";
?>
<div class="faculty">
<p style="font-size:18px;text-
align:center;background:#1abc9c;color:#fff;padding:10px;margin:0">Welcome : <?php echo $funame; ?> <i
class="fa fa-check-circle" aria-hidden="true"></i></p>
<table class="tab_one">
<?php
$getuser = $user->get_faculty_by_username($funame);
while($row = $getuser->fetch_assoc()){
?>
<tr>
<td style="text-align:center">Name: </td>
<td><?php echo $row['name']; ?></td>
</tr>
<tr>
<td style="text-align:center">Username: </td>
<td><?php echo $row['username']; ?></td>
</tr>
<tr>
<td style="text-align:center">E-mail: </td>
<td><?php echo $row['email']; ?></td>
</tr>
<tr>
<td style="text-align:center">Birthday: </td>
<td><?php echo $row['birthday']; ?></td>
</tr>
<tr>
<td style="text-align:center">Education: </td>
<td><?php echo $row['education']; ?></td>
</tr>
<tr>
<td style="text-align:center">Contact: </td>
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:83
University Management System
<?php } } ?>
</table>
</div>
<?php
include "php/footerbottom.php";
ob_end_flush();
?>
Footer
</div>
</div>
Header
<!Doctype html>
<html class="no-js" lang="">
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<title><?php echo $pageTitle; ?></title>
<meta name="description" content="University Management system">
<meta name="author" content="Md Abul Kalam">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Place favicon.ico in the root directory -->
</ul>
</div>
</div>
<div class="content fix">
Index
<?php
ob_start ();
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
if($user->get_admin_session()){
header('Location: admin.php');
exit();
}
?>
<?php
$pageTitle = "Admin Login";
?>
<?php include "header.php"; ?>
if(empty($username) or empty($password)){
echo "<p style='color:red;text-align:center;'>Field must not be empty.</p>";
}else{
$password = md5($password);
$login = $user->admin_userlogin($username, $password);
if($login){
header('Location: admin.php');
}else{
echo "<p style='color:red;text-align:center'>Incorrect username or password</p>";
}
}
}
?>
<form action="" method="post">
<input type="text" name="username" placeholder="Username" />
<input type="password" name="password" placeholder="Password" />
<input type="submit" value="Login" />
</form>
</div>
</div>
St change pass
<?php
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:87
University Management System
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$sid = $_SESSION['sid'];
$sname = $_SESSION['sname'];
if(!$user->getsession()){
header('Location: st_login.php');
exit();
}
?>
<?php
$pageTitle = "Change Password";
include "php/headertop.php";
?>
<div class="profile">
<h3 style="font-size:18px;text-
align:center;background:#1abc9c;color:#fff;padding:10px;margin:0">Update Your
Profile</h3>
<?php
if($_SERVER['REQUEST_METHOD'] == "POST"){
$oldpass = $_POST['oldpass'];
$newpass = $_POST['newpass'];
$confirmpass = $_POST['confirmpass'];
if(empty($newpass) or empty($oldpass) or empty($confirmpass)){
echo "<p style='color:red;text-align:center'>Field must not be empty.</p>";
}elseif($newpass != $confirmpass){
echo "<p style='color:red;text-align:center'>Password not matched.</p>";
}else{
$oldpass = md5($oldpass);
$newpass = md5($newpass);
$user->updatePassword($sid, $newpass, $oldpass);
}
}
?>
<td>New Password:</td>
<td><input type="text" name="newpass" placeholder="New password" /></td>
</tr>
<tr>
<td style="width:125px;"></td>
<td>Confirm Password:</td>
<td><input type="text" name="confirmpass" placeholder="Confirm password" /></td>
</tr>
<tr>
<td style="width:125px;"></td>
<td></td>
<td colspan="2">
<input style="background:#3498db;color:#fff;width:168px;border-radius:5px;"
type="submit" name="Update" value="Update">
</td>
</tr>
</table>
<?php } ?>
</form>
</div>
<div class="back fix">
<p style="text-align:center"><a href="st_profile.php"><button class="editbtn">Back to your
Profile</button></a></p>
</div>
</div>
St login
<?php
ob_start ();
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
if($user->getsession()){
header('Location: st_profile.php');
exit();
}
?>
<?php
$pageTitle = "Student login";
include "header.php";
?>
<div class="loginform fix">
<div class="msg"><h3><i class="fa fa-graduation-cap" aria-hidden="true"></i>Student
login</h3></div>
<div class="access">
<?php
if($_SERVER['REQUEST_METHOD'] == "POST"){
$st_id = $_POST['st_id'];
$st_pass = $_POST['st_pass'];
if(empty($st_id) or empty($st_pass)){
echo "<p style='color:red;text-align:center;'>Field must not be empty.</p>";
}else{
$st_pass = md5($st_pass);
$login = $user->st_userlogin($st_id, $st_pass);
if($login){
header('Location: st_profile.php');
}else{
echo "<p style='color:red;text-align:center'>Incorrect Student ID or password</p>";
}
}
}
?>
St logout
<?php
ob_start();
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$user->st_logout();
header('Location: st_login.php');
exit();
ob_end_flush();
?>
St profile
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$sid = $_SESSION['sid'];
$sname = $_SESSION['sname'];
if(!$user->getsession()){
header('Location: st_login.php');
exit();
}
?>
<?php
$pageTitle = "Student Profile";
include "php/headertop.php";
?>
<div class="profile">
<p style="font-size:18px;text-
align:center;background:#1abc9c;color:#fff;padding:10px;margin:0">Welcome : <?php $user-
>getusername($sid); ?> <i class="fa fa-check-circle" aria-hidden="true"></i></p>
<table class="tab_one">
<?php
$getuser = $user->getuserbyid($sid);
while($row = $getuser->fetch_assoc()){
?>
<tr>
<td></td>
<?php if(empty($row['img'])){?>
<td><img src="img/default.png" style="height:180px; width:180px; border:1px #1ABC9C
solid;border-radius:90px" alt="" /></td>
<?php }else{ ?>
<td><img src="img/student/<?php echo $row['img']; ?>" style="height:180px; width:180px;
border:1px #1ABC9C solid;border-radius:90px" alt="" /></td>
<?php }?>
</tr>
<tr >
<td><b>Student ID:</b> </td>
<td><?php echo $row['st_id']; ?></td>
</tr>
<tr>
<td><b>Name:</b> </td>
<td><?php echo $row['name']; ?></td>
</tr>
<tr>
<td><b>E-mail:</b> </td>
<td><?php echo $row['email']; ?></td>
</tr>
<tr>
<td><b>Birthday:</b> </td>
<td><?php echo $row['bday']; ?></td>
</tr>
<tr>
<td><b>Program:</b> </td>
<td><?php echo $row['program']; ?></td>
</tr>
<tr>
<td><b>Contact:</b> </td>
<td><?php echo $row['contact']; ?></td>
</tr>
<tr>
<td><b>Gender:</b> </td>
<td><?php echo $row['gender']; ?></td>
</tr>
<tr>
<td><b>Address:</b> </td>
<td><?php echo $row['address']; ?></td>
</tr>
<?php if($row['st_id'] == $sid){ ?>
<tr>
<td><b>Update Profile:</b> </td>
<td><a href="st_update.php?id=<?php echo $row['st_id'];?>"><button class="editbtn">Edit
Profile</button></a></td>
</tr>
<?php } } ?>
</table>
</div>
St reg
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
if($user->getsession()){
header('Location: st_profile.php');
}
?>
<?php
$pageTitle = "Student Registration";
include "header.php";
?>
<div class="st_reg fix">
<h2>Student Registration Form</h2>
<p class="msg">
<?php
if($_SERVER['REQUEST_METHOD'] == "POST"){
$st_id = $_POST['st_id'];
$st_name = $_POST['st_name'];
$st_pass = $_POST['st_pass'];
$st_email = $_POST['st_email'];
$BirthMonth = $_POST['BirthMonth'];
$BirthDay = $_POST['BirthDay'];
$BirthYear = $_POST['BirthYear'];
$bday = "{$BirthYear}-{$BirthMonth}-{$BirthDay}";
$st_dept = $_POST['st_dept'];
$st_contact = $_POST['st_contact'];
$st_gender = $_POST['gender'];
$st_add = $_POST['st_add'];
</p>
<form action="" method="post" id="st_form">
<table>
<tr>
<th>Name: </th>
<td><input type="text" name="st_name" placeholder="Full Name" required /></td>
</tr>
<tr>
<tr>
<th>Student ID: </th>
<td><input type="text" name="st_id" placeholder="Student Id" required /></td>
</tr>
<tr>
<th>Password: </th>
<td><input type="password" name="st_pass" placeholder="password" required /></td>
</tr>
<tr>
<th>E-mail: </th>
<td><input type="email" name="st_email" placeholder="example@email.com" required
/></td>
</tr>
<tr>
<th>Date of Birth: </th>
<td>
<fieldset>
<option value="02">Feb</option>
<option value="04">April</option>
<option value="05">May</option>
<option value="06">June</option>
<option value="07">July</option>
<option value="08">Aug</option>
<option value="09">Sep</option>
<option value="10">Oct</option>
<option value="11">Nov</option>
<option value="12" >Dec</option>
</label>
</select>
</fieldset>
</td>
</tr>
<tr>
<th>Program:</th>
<td><input type="text" name="st_dept" placeholder="BCSE,BSEEE, BBA..." required /></td>
</tr>
<tr>
<th>Contact:</th>
<td><input type="text" name="st_contact" placeholder="phone" required /></td>
</tr>
<tr>
<th>Gender:</th>
<td><label><input type="radio" name="gender" value="Male" checked/> Male</label>
<label><input type="radio" name="gender" value="Female"/> Female</label>
<label><input type="radio" name="gender" value="Other"/> Other</label>
</td>
</tr>
<tr>
<th>Address:</th>
<td><input type="text" name="st_add" placeholder="Address" required /></td>
</tr>
<tr>
<td colspan="2"><input type="submit" name="sub" value="Register" /></td>
</tr>
</table>
</form>
</div>
St result
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
if(isset($_REQUEST['ar'])){
$stid = $_REQUEST['ar'];
$name = $_REQUEST['vn'];
$semester = $_REQUEST['seme'];
}
?>
<?php
$pageTitle = "update Student Result";
include "php/headertop_admin.php";
?>
<div class="all_student fix">
<div>
<p style="text-align:center;color:#fff;background:purple;margin:0;padding:8px;"><?php echo "Name:
".$name."<br>ID: ".$stid."<br>Semester: " . $semester; ?></p>
</div>
<?php
if($_SERVER['REQUEST_METHOD'] == 'POST'){
$subject = $_POST['umark'];
$res = $user->update_result($stid,$subject,$semester);
//var_dump($res);
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:95
University Management System
if($res){
echo "<h3 style='color:green;margin:0;padding:0;text-align:center'>Marks successfully
updated!</h3>";
}else{
echo "<p style='color:red;text-align:center'>Failed to update data</p>";
}
}
?>
</tr>
<?php
$i=0;
$get_result = $user->show_marks($stid,$semester);
while($rows = $get_result->fetch_assoc()){
$i++;
?>
<tr>
<td><?php echo $rows['sub'];?></td>
<td><input type="text" name="umark[<?php echo $rows['sub'];?>]" value="<?php echo
$rows['marks'];?>"/></td>
</tr>
<?php } ?>
<tr><td colspan="2"><input type="submit" value="Update Result" /></td></tr>
</table>
</form>
<div class="back fix">
<p style="text-align:center"><a href="view_result.php?vr=<?php echo $stid?>&vn=<?php echo
$name?>"><button class="editbtn">go to result page</button></a></p>
</div>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
St result update
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:96
University Management System
</tr>
<?php
$i=0;
$alluser = $user->get_all_student();
while($rows = $alluser->fetch_assoc()){
$i++;
?>
<tr>
<td><?php echo $i;?></td>
<td><?php echo $rows['name'];?></td>
<td><?php echo $rows['st_id'];?></td>
<td><a href="add_result.php?ar=<?php echo $rows['st_id']; ?>&vn=<?php echo
$rows['name'];?>">Add Result</a></td>
<td><a href="view_result.php?vr=<?php echo $rows['st_id']; ?>&vn=<?php echo
$rows['name'];?>">View Result</a></td>
</tr>
<?php } ?>
</table>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
St update
<?php
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:97
University Management System
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$sid = $_SESSION['sid'];
$sname = $_SESSION['sname'];
/*
if(isset($_REQUEST['id'])){
$id = $_REQUEST['id'];
}else{
header('Location: index.php');
exit();
}
*/
if(!$user->getsession()){
header('Location: st_login.php');
exit();
}
?>
<?php
$pageTitle = "Update Profile";
include "php/headertop.php";
?>
<script>
function PreviewImage(upname, prv_id) {
var oFReader = new FileReader();
oFReader.readAsDataURL(document.getElementsByName(upname)[0].files[0]);
</script>
<div class="profile">
<h3 style="font-size:18px;text-
align:center;background:#1abc9c;color:#fff;padding:10px;margin:0">Update Your
Profile</h3>
<?php
$qry=$user->getuserbyid($sid);
$pic=$qry->fetch_assoc();
$piclocation=$pic['img'];
if($_SERVER['REQUEST_METHOD'] == "POST"){
//code for img
function guid() {
if (function_exists('com_create_guid')) {
return com_create_guid();
} else {
if($_FILES["personal_image"]["name"])
{
$path_parts = pathinfo($_FILES["personal_image"]["name"]);
$ext = $path_parts['extension'];
$fileName = trim(guid(), '{}') . '.' . $ext;
}
else{
$fileName = $piclocation;
}
move_uploaded_file($_FILES['personal_image']['tmp_name'], "img/student/$fileName");
//end img
$st_name = $_POST['st_name'];
$st_email = $_POST['st_email'];
$st_dept = $_POST['st_dept'];
$st_contact = $_POST['st_contact'];
$st_gender = $_POST['st_gender'];
$st_add = $_POST['st_add'];
if(empty($st_name) or empty($st_email) or empty($st_contact) or empty($st_dept) or
empty($st_gender) or empty($st_add)){
echo "<p style='color:red;text-align:center'>Field must not be empty.</p>";
}else{
$update = $user-
>updateprofile($sid,$st_name,$st_email,$st_dept,$st_gender,$st_contact,$st_add,$fileName);
if($update){
echo "<h4 style='color:green;text-align:center'>Information Updated
successfully</h4>";
}else{
echo "<h4 style='color:red;text-align:center;text-align:center'>Failed to update</h4>";
}
}
}
?>
</td>
</tr>
</table>
<?php } ?>
</form>
</div>
<div class="back fix">
<p style="text-align:center"><a href="st_profile.php"><button class="editbtn">Back to your
Profile</button></a></p>
</div>
</div>
<?php
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
require('plugins/fpdf/fpdf.php');
require('plugins/fpdf/rotation.php');
$pdf->Image('img/logo.png',10,9,17);
$pdf->Ln();
$pdf-> Cell(20);
$pdf->SetFont('Times','',14);
$pdf->Write(5, $iubat);
$pdf->Ln();
$pdf-> Cell(22);
$pdf->SetFont('Times','',10);
$pdf->Write(4,'Developed by Md Abul Kalam');
$pdf-> Cell(20);
$pdf->SetFont('Times','',8);
$pdf->Write(5,
'_______________________________________________________________________________________
___________________________________________');
$pdf->Ln();
$pdf->Ln();
$pdf-> Cell(85);
$pdf->SetFont('Times','U',10);
$pdf->Write(5, 'Student List');
$pdf->Ln();
$pdf->Ln(2);
$pdf-> Cell(5);
$pdf->SetFont('Times','B',8);
$pdf->Cell(8,6,'SL',1);
$pdf->Cell(20,6,'Student ID',1);
$pdf->Cell(40,6,'Student Name',1);
$pdf->Cell(40,6,'Contact',1);
$pdf->Cell(40,6,'Email',1);
$pdf->Cell(22,6,'Picture',1);
$pdf->Ln();
$qry = $user->get_all_student();
$sl=1;
while($rec = $qry->fetch_assoc())
{
$pdf-> Cell(5);
$pdf->SetFont('Times','',8);
$pdf->Cell(8,20,$sl,1);
$pdf->Cell(20,20,$rec['st_id'],1);
$pdf->Cell(40,20,$rec['name'],1);
$pdf->Cell(40,20,$rec['contact'],1);
$pdf->Cell(40,20,$rec['email'],1);
$image1='img/student/'.$rec['img'];
$pdf->Cell( 22, 20, $pdf->Image($image1, $pdf->GetX(), $pdf->GetY(),22, 20), 1, 0, 'L',
false);
$sl++;
$pdf->Ln();
}
$pdf->Ln();
$pdf->Ln();
$pdf->Output();
?>
View cgpa
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
if(isset($_REQUEST['vr'])){
$stid = $_REQUEST['vr'];
$name = $_REQUEST['vn'];
}
?>
<?php
$pageTitle = "Student Result";
include "php/headertop_admin.php";
?>
<div class="all_student fix">
<?php
//$get_result = $user->show_marks();
$get_result = $user->view_cgpa($stid);
//var_dump($get_result);
if($get_result && ($get_result->num_rows)>0){
?>
?>
<tr>
<td><?php echo $rows['sub']; ?></td>
<td><?php echo $rows['marks']; ?></td>
<td>
<?php
//set grade for individual subject
$mark = $rows['marks'];
if($mark<60){echo "F";}
?>
</td>
<td><?php echo credit_hour($rows['sub']); ?></td>
<td>
<?php
$stat = $rows['marks'];
if($stat<60){
echo "<span style='background:red;padding:3px 11px;color:#fff;'>Fail</span>";
}elseif($stat>=60 && $stat<70){
echo "<span style='background:yellow'>Retake</span>";
}else{
echo "<span style='background:green;padding:3px 6px;color:#fff;'>Pass</span>";
}
?>
</td>
</tr>
<?php } ?>
<tr>
<td><?php echo "Total Course: <span style='color:#800080;padding:3px 6px;font-
size:22px'>".$i."</span>"; ?></td>
<td colspan="1">Total CGPA : </td>
<td colspan="2">
<?php
$sg = $gp/$ch;
echo "<span style='color:green;padding:3px 6px;font-size:22px'>" . round($sg,2) . "</span>"; ?>
</td>
<td>
<?php
if($sg>=3.5){
echo "<span style='background:purple;padding:3px 6px;color:#fff;'>Excellent";
}elseif($sg>=3.0 && $sg<3.5){
echo "<span style='background:green;padding:3px 6px;color:#fff;'>Good";
}elseif($sg>=2.5 && $sg<3.0){
echo "<span style='background:gray;padding:3px 6px;color:#fff;'>Average";
}else{
echo "<span style='background:red;padding:3px 6px;color:#fff;'>Probation";
}
?>
</td>
</tr>
</table>
<?php
}
else{
echo "<p style='color:red;text-align:center'>Nothing Found</p>";
}
?>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
View result
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$admin_id = $_SESSION['admin_id'];
$admin_name = $_SESSION['admin_name'];
if(!$user->get_admin_session()){
header('Location: index.php');
exit();
}
if(isset($_REQUEST['vr'])){
$stid = $_REQUEST['vr'];
$name = $_REQUEST['vn'];
}
?>
<?php
$pageTitle = "Student Result";
include "php/headertop_admin.php";
?>
<div class="all_student fix">
<?php
</form>
<?php
//select semester
if($_SERVER['REQUEST_METHOD'] == 'POST'){
$semester = $_POST['seme'];
$i=0;
$ch = 0;
$gp = 0;
//$get_result = $user->show_marks();
$get_result = $user->show_marks($stid,$semester);
if($get_result){
?>
<p><?php echo "<p style='text-
align:center;background:#ddd;color:#01C3AA;padding:5px;width:84%;margin:0 auto'>".$semester."
Semester Result"?></p>
<table class="tab_two" style="text-align:center;width:85%;margin:0 auto">
<th>Subject</th>
<th>Marks</th>
<th>Grade</th>
<th>Credit hr.</th>
<th>Status</th>
<?php
while($rows = $get_result->fetch_assoc()){
$i++;
//count total credit hour;
$ch = $ch + credit_hour($rows['sub']);
?>
<tr>
<td><?php echo $rows['sub'];?></td>
<td><?php echo $rows['marks'];?></td>
<td>
<?php
//set grade for individual subject
$mark = $rows['marks'];
if($mark<60){echo "F";}
elseif($mark>=60 && $mark<70){echo "D";}
elseif($mark>=70 && $mark<80){echo "C";}
elseif($mark>=80 && $mark<90){echo "B";}
elseif($mark>=90 && $mark<=100){echo "A";}
?>
</td>
<td><?php echo credit_hour($rows['sub']); ?></td>
<td>
<?php
$stat = $rows['marks'];
if($stat<60){
echo "<span style='background:red;padding:3px 11px;color:#fff;'>Fail</span>";
}elseif($stat>=60 && $stat<70){
echo "<span style='background:yellow'>Retake</span>";
}else{
echo "<span style='background:green;padding:3px 6px;color:#fff;'>Pass</span>";
}
?>
</td>
</tr>
<?php } ?>
<tr>
<td colspan="2">SGPA : </td>
<td colspan="2">
<?php
$sg = $gp/$ch;
echo "<span style='color:green;padding:3px 6px;font-size:20px'>" . round($sg,2) . "</span>"; ?>
</td>
<td>
<?php
if($sg>=3.5){
echo "<span style='background:purple;padding:3px 6px;color:#fff;'>Excellent";
}elseif($sg>=3.0 && $sg<3.5){
echo "<span style='background:green;padding:3px 6px;color:#fff;'>Good";
}elseif($sg>=2.5 && $sg<3.0){
echo "<span style='background:gray;padding:3px 6px;color:#fff;'>Average";
}else{
echo "<span style='background:red;padding:3px 6px;color:#fff;'>Probation";
}
?>
</td>
</tr>
</table>
<?php
}
else{
echo "<p style='color:red;text-align:center'>Nothing Found</p>";
}
?>
<p style="float:left; text-align:right;margin:20px 0;width:49%"><a
href="st_result_update.php?ar=<?php echo $stid?>&seme=<?php echo $semester?>&vn=<?php echo
$name?>"><button class="editbtn">Edit Result</button></a></p>
<?php
}
?>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$sid = $_SESSION['sid'];
$sname = $_SESSION['sname'];
if(!$user->getsession()){
header('Location: st_login.php');
exit();
}
if(isset($_REQUEST['vr'])){
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:109
University Management System
$stid = $_REQUEST['vr'];
$name = $_REQUEST['vn'];
}
?>
<?php
$pageTitle = "Student Result";
include "php/headertop.php";
?>
<div class="all_student fix">
<?php
//$get_result = $user->show_marks();
$get_result = $user->view_cgpa($stid);
//var_dump($get_result);
?>
<tr>
<td><?php echo $rows['sub']; ?></td>
<td><?php echo $rows['marks']; ?></td>
<td>
<?php
//set grade for individual subject
$mark = $rows['marks'];
if($mark<60){echo "F";}
elseif($mark>=60 && $mark<70){echo "D";}
elseif($mark>=70 && $mark<80){echo "C";}
elseif($mark>=80 && $mark<90){echo "B";}
elseif($mark>=90 && $mark<=100){echo "A";}
?>
</td>
<td><?php echo credit_hour($rows['sub']); ?></td>
<td>
<?php
$stat = $rows['marks'];
if($stat<60){
echo "<span style='background:red;padding:3px 11px;color:#fff;'>Fail</span>";
}elseif($stat>=60 && $stat<70){
echo "<span style='background:yellow'>Retake</span>";
}else{
echo "<span style='background:green;padding:3px 6px;color:#fff;'>Pass</span>";
}
?>
</td>
</tr>
<?php } ?>
<tr>
<?php
}
else{
echo "<p style='color:red;text-align:center'>Nothing Found</p>";
}
?>
</div>
<?php include "php/footerbottom.php";?>
<?php ob_end_flush() ; ?>
<?php
session_start();
require "php/config.php";
require_once "php/functions.php";
$user = new login_registration_class();
$sid = $_SESSION['sid'];
$sname = $_SESSION['sname'];
if(!$user->getsession()){
header('Location: st_login.php');
Dept.of (CS)[2022-2023] V.K Krishna Menon College Page No:112
University Management System
exit();
}
if(isset($_REQUEST['vr'])){
$stid = $_REQUEST['vr'];
$name = $_REQUEST['vn'];
}
?>
<?php
$pageTitle = "Student Result";
include "php/headertop.php";
?>
<div class="all_student fix">
<?php
</form>
<div class="fix">
<p style="float:left;margin:0 0 3px 0;width:100%;text-align:center;"><a
href="view_single_cgpa.php?vr=<?php echo $stid; ?>&vn=<?php echo $name; ?>"><button
$i=0;
$ch = 0;
$gp = 0;
//$get_result = $user->show_marks();
$get_result = $user->show_marks($stid,$semester);
if($get_result){
?>
<p><?php echo "<p style='text-
align:center;background:#ddd;color:#01C3AA;padding:5px;width:84%;margin:0 auto'>".$semester."
Semester Result"?></p>
<table class="tab_two" style="text-align:center;width:85%;margin:0 auto">
<th>Subjects</th>
<th>Marks</th>
<th>Grade</th>
<th>Credit hr.</th>
<th>Status</th>
<?php
while($rows = $get_result->fetch_assoc()){
$i++;
//count total credit hour;
$ch = $ch + credit_hour($rows['sub']);
?>
<tr>
<td><?php echo $rows['sub'];?></td>
<td><?php echo $rows['marks'];?></td>
<td>
<?php
//set grade for individual subject
$mark = $rows['marks'];
if($mark<60){echo "F";}
elseif($mark>=60 && $mark<70){echo "D";}
elseif($mark>=70 && $mark<80){echo "C";}
elseif($mark>=80 && $mark<90){echo "B";}
elseif($mark>=90 && $mark<=100){echo "A";}
?>
</td>
<td><?php echo credit_hour($rows['sub']); ?></td>
<td>
<?php
$stat = $rows['marks'];
if($stat<60){
echo "<span style='background:red;padding:3px 11px;color:#fff;'>Fail</span>";
}elseif($stat>=60 && $stat<70){
echo "<span style='background:yellow'>Retake</span>";
}else{
echo "<span style='background:green;padding:3px 6px;color:#fff;'>Pass</span>";
}
?>
</td>
</tr>
<?php } ?>
<tr>
<td colspan="2">SGPA : </td>
<td colspan="2">
<?php
$sg = $gp/$ch;
echo "<span style='color:green;padding:3px 6px;font-size:20px'>" . round($sg,2) . "</span>"; ?>
</td>
<td>
<?php
if($sg>=3.5){
echo "<span style='background:purple;padding:3px 6px;color:#fff;'>Excellent";
}elseif($sg>=3.0 && $sg<3.5){
echo "<span style='background:green;padding:3px 6px;color:#fff;'>Good";
}elseif($sg>=2.5 && $sg<3.0){
echo "<span style='background:gray;padding:3px 6px;color:#fff;'>Average";
}else{
echo "<span style='background:red;padding:3px 6px;color:#fff;'>Probation";
}
?>
</td>
</tr>
</table>
<?php
}
else{
echo "<p style='color:red;text-align:center'>Nothing Found</p>";
}
}
?>
</div>
6. Database table
7. Screenshots
7.1 Administrator Login
7.8 Attendance
7.16 Result
Conclusions:
The university management system improves the institution’s work organization and decreas
es the amount of paperwork that wastes time.
If youwish to enroll in a university, you must first register in the system and obtain all of the
essential information.
The goal of this research was to create a university management project system that would
aid in the maintenance of university records. Creating strategies for efficient management
and handling of a task in every university. The university management system project
includes features that allow for quick access to donor records gathered across the country.
9.References
9.1 Website:
1. Https://www.getboostrap.com
2. Https://www.w3schools.com
3. Https://www.Youtube.com
4. Https://www.php.net
9.2 Books:
1. Head First PHP & MySQL: A Brain-Friendly Guide Paperback
- Lynn Beighley (Author)
2. HTML 5 Black Book, Covers CSS 3, JavaScript, XML, XHTML, AJAX,
PHP and jQuery
- DT Editorial Services (Author)