Skip to content

Commit d0d7ffb

Browse files
committed
commit 2
1 parent 01a7744 commit d0d7ffb

15 files changed

+11050
-237
lines changed

admin.css

+125
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,125 @@
1+
.banner{
2+
background-image:url('img/adminbanner.jpg');
3+
background-attachment: fixed;
4+
text-align: center;
5+
border-radius:20px;
6+
display:inline-block;
7+
min-width:100%;
8+
border: black solid 2px;
9+
border-bottom-right-radius:600px;
10+
border-bottom-left-radius:600px;
11+
box-shadow: black 10px 10px 20px;
12+
13+
}
14+
15+
#logo{
16+
width: auto;
17+
max-width: 15%;
18+
}
19+
body{
20+
font-family: "Arial", Times, serif;
21+
}
22+
.bannertext{
23+
font-size: 2.3em;
24+
color: white;
25+
text-shadow: black 0px 1px 30px;
26+
}
27+
.nav{
28+
color:black;
29+
text-decoration:none;
30+
padding:15px;
31+
background:#00EAFF;
32+
display:inline-block;
33+
min-width: 17.7%;
34+
border-top-right-radius:100px;
35+
border-bottom-left-radius:100px;
36+
font-size:1.25em;
37+
}
38+
.nav:hover{
39+
color:white;
40+
background-color:#ff1aff;
41+
}
42+
nav{
43+
background:black;
44+
padding:5px;
45+
border-radius:5px;
46+
text-align: center;
47+
display:inline-block;
48+
min-width:100%;
49+
box-shadow: black 10px 10px 20px;
50+
border-top-right-radius:100px;
51+
border-bottom-left-radius:100px;
52+
position:sticky;
53+
position:-webkit-sticky;
54+
top:0;
55+
}
56+
#home,#register,#login{
57+
padding-top: 20px;
58+
display:block;
59+
min-width:100%;
60+
display:none;
61+
}
62+
#home{
63+
display:block;
64+
}
65+
.title{
66+
color:#00EAFF;
67+
font-weight:bold;
68+
background-color:#083854;
69+
border-radius:10px;
70+
padding:20px;
71+
display:inline-block;
72+
min-width:70%;
73+
border-top-right-radius:100px;
74+
border-bottom-left-radius:100px;
75+
text-shadow:black 0px 0px 20px;
76+
box-shadow: black 10px 10px 20px;
77+
}
78+
.content,dl{
79+
border:black solid;
80+
border-radius:20px;
81+
box-shadow: black 10px 10px 20px;
82+
border-top-right-radius:200px;
83+
border-bottom-left-radius:200px;
84+
}
85+
dt,.heading{
86+
color:#083854;
87+
margin-left: 10%;
88+
font-weight: bold;
89+
font-size: 1.5em;
90+
}
91+
dd{
92+
margin-left: 15%;
93+
}
94+
.design{
95+
z-index:-999;
96+
float:right;
97+
width:auto;
98+
max-width: 25%;
99+
position:absolute;
100+
right:10px;
101+
}
102+
input{
103+
float:right;
104+
min-width: 50%;
105+
margin-right:30%;
106+
paddig:30px;
107+
border-top-right-radius:15px;
108+
border-bottom-left-radius:15px;
109+
font-size: 1em;
110+
}
111+
.wrap{
112+
text-align: center;
113+
display:block;
114+
}
115+
#message{
116+
display: none;
117+
font-weight: bold;
118+
border:black solid;
119+
border-radius: 6px;
120+
padding:10px;
121+
min-width:60%;
122+
border-top-right-radius: 40px;
123+
border-bottom-left-radius: 40px;
124+
box-shadow: black 5px 5px 10px;
125+
}

admin.js

+71
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
/*
2+
* Javascript ::
3+
*/
4+
document.getElementById('password').addEventListener("keyup",function(){
5+
var reg = document.getElementById('register_button');
6+
var pass = document.getElementById('password');
7+
var conf_pass = document.getElementById('conf_pass');
8+
var message = document.getElementById("message");
9+
if(pass.value == conf_pass.value){
10+
reg.style.opacity=1;
11+
reg.style.backgroundColor="tomato";
12+
reg.setAttribute('onmouseenter','this.style.backgroundColor="#ff1aff"');
13+
reg.setAttribute('onmouseleave','this.style.backgroundColor="tomato"');
14+
reg.disabled=false;
15+
message.style.color="green";
16+
message.style.display="inline-block";
17+
message.innerHTML='Password Matched';
18+
}
19+
else{
20+
reg.style.backgroundColor="#BFC9CA";
21+
reg.style.opacity=0.5;
22+
reg.removeAttribute('onmouseenter');
23+
reg.removeAttribute('onmouseleave');
24+
reg.disabled=true;
25+
message.innerHTML='Password not Matching';
26+
message.style.color='red';
27+
message.style.display="inline-block";
28+
}
29+
30+
});
31+
document.getElementById('conf_pass').addEventListener("keyup",function(){
32+
var reg = document.getElementById('register_button');
33+
var pass = document.getElementById('password');
34+
var conf_pass = document.getElementById('conf_pass');
35+
var message = document.getElementById("message");
36+
if(pass.value == conf_pass.value){
37+
reg.style.opacity=1;
38+
reg.style.backgroundColor="tomato";
39+
reg.setAttribute('onmouseenter','this.style.backgroundColor="#ff1aff"');
40+
reg.setAttribute('onmouseleave','this.style.backgroundColor="tomato"');
41+
reg.disabled=false;
42+
message.style.color="green";
43+
message.style.display="inline-block";
44+
message.innerHTML='Password Matched';
45+
}
46+
else{
47+
reg.style.backgroundColor="#BFC9CA";
48+
reg.style.opacity=0.5;
49+
reg.removeAttribute('onmouseenter');
50+
reg.removeAttribute('onmouseleave');
51+
reg.disabled=true;
52+
message.innerHTML='Password not Matching';
53+
message.style.color='red';
54+
message.style.display="inline-block";
55+
document.getElementById("message").innerHTML = serialize(document.forms[0]);
56+
}
57+
58+
});
59+
if(response!=0){
60+
document.getElementById('message').style.display='inline-block';
61+
document.getElementById('message').innerHTML=response;
62+
}
63+
64+
/*
65+
* JQuery ::
66+
*/
67+
function show(x){
68+
$("#register , #home, #login").hide();
69+
$('#'+x).fadeIn();
70+
71+
}

admins.php

+102
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
<?php
2+
session_start();
3+
?>
4+
<!DOCTYPE html>
5+
<!--Sayan Pandey 15/IT/21-->
6+
<html lang='en'>
7+
<head>
8+
<title>Administrators' Portal</title>
9+
<meta charset="utf-8">
10+
<meta name="viewport" content="width=device-width, initial-scale=1">
11+
<link rel="stylesheet" type="text/css" href="admin.css">
12+
</head>
13+
<body>
14+
<div class="banner">
15+
<img id="logo" src="img/logo.png">
16+
<h1 class="bannertext">National Institute of Technology DURGAPUR, West Bengal</h1>
17+
<h1 class="bannertext">Administrators' Portal</h1>
18+
</div>
19+
<nav>
20+
<a class="nav" onclick="show('home')">Home</a>
21+
<a class="nav" onclick="show('register')">Register</a>
22+
<a class="nav" onclick="show('login')">Login</a>
23+
<a class="nav" >Profile</a>
24+
<a class="nav" >Logout</a>
25+
</nav>
26+
<!--Home-->
27+
<div id="home">
28+
<h1 class="title" style="font-size: 3em">&nbsp;&nbsp;Home</h1>
29+
<!--content-->
30+
<div class="content">
31+
<h1>&nbsp;&nbsp;&nbsp;&nbsp;Welcome!! Click on the navigation buttons for following functionalities:</h1>
32+
</div>
33+
<h3>
34+
<dl style="padding:15px;">
35+
<img class="design" src="img/back2.png">
36+
<dt>Home:</dt>
37+
<dd>Click on 'Home' to return here.</dd>
38+
<br>
39+
<dt>Register:</dt>
40+
<dd>Click on 'Register' on the navigation bar to register yourself with this portal.</dd>
41+
<br>
42+
<dt>Login:</dt>
43+
<dd>Click on 'Login' on the navigation bar to register yourself with this portal.</dd>
44+
<br>
45+
<dt>Profile:</dt>
46+
<dd>Click on 'Profile' to check your profile (Login Required).</dd>
47+
<br>
48+
<dt>Logout:</dt>
49+
<dd>Click on 'Logout' to end session.</dd>
50+
</dl>
51+
</h3>
52+
</div>
53+
<!--Register-->
54+
<div id="register">
55+
<h1 class="title" style="font-size: 3em">&nbsp;&nbsp;Register</h1>
56+
<!--content-->
57+
<div class="content">
58+
<img class="design" src="img/back2.png">
59+
<h1>&nbsp;&nbsp;&nbsp;&nbsp;Fill up the details:</h1>
60+
<form method="POST" action='reg.php'>
61+
<h3 class="heading">Registration Number:&nbsp;<input type="number" name="regno" placeholder="Enter Registration number" required></h3>
62+
<h3 class="heading">Roll Number:&nbsp;<input type="text" name="rollno" placeholder="Enter Roll number" required></h3>
63+
<h3 class="heading">Name:&nbsp;<input type="text" name="name" placeholder="Enter your name" required></h3>
64+
<h3 class="heading">Phone:&nbsp;<input type="number" name="phone" placeholder="Enter your phone number" required></h3>
65+
<h3 class="heading">Email Id:&nbsp;<input type="email" name="email" placeholder="Enter email" required></h3>
66+
<h3 class="heading">Password:&nbsp;<input type="password" id="password" name="password" placeholder="Enter password" required></h3>
67+
<h3 class="heading">Confirm Password:&nbsp;<input type="password" id="conf_pass" placeholder="Re-enter password" required></h3>
68+
<div class="wrap"><h4 id="message"></h4></div>
69+
<div class="wrap"><button class="nav" id="register_button" type="submit">Register</button></div>
70+
<br>
71+
</form>
72+
</div>
73+
</div>
74+
<!--Login-->
75+
<div id="login">
76+
<h1 class="title" style="font-size: 3em">&nbsp;&nbsp;Login</h1>
77+
<!--content-->
78+
<div class="content">
79+
<img style=" z-index:-999;
80+
float:right;
81+
width:auto;
82+
max-width: 17%;
83+
position:absolute;
84+
right:10px;" src="img/back2.png">
85+
<h1>&nbsp;&nbsp;&nbsp;&nbsp;Fill up the details:</h1>
86+
<form>
87+
<h3 class="heading">Registration Number:&nbsp;<input type="number" name="regno" placeholder="Enter Registration number" required></h3>
88+
<h3 class="heading">Password:&nbsp;<input type="password" name="password" placeholder="Enter password" required></h3>
89+
<div class="wrap"><button class="nav" type="submit">Login</button></div>
90+
<br>
91+
</form>
92+
</div>
93+
</div>
94+
</body>
95+
<script>var response= "<?php echo isset($_SESSION['response'])?$_SESSION['response']:0; ?>"</script>
96+
<script src="admin.js"></script>
97+
<script src="jquery3.3.1.js"></script>
98+
</html>
99+
<?php
100+
session_unset();
101+
session_destroy();
102+
?>

img/adminbanner.jpg

555 KB
Loading

img/administrator.png

72.3 KB
Loading

img/mainbanner.jpg

495 KB
Loading

img/student.png

38.9 KB
Loading

0 commit comments

Comments
 (0)