Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
KLUGLUG
Blood Service Portal
Commits
7adb0305
Commit
7adb0305
authored
Nov 14, 2019
by
rama chandra
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added create admin
parent
77debd95
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
49 additions
and
0 deletions
+49
-0
admin/createadmin.php
admin/createadmin.php
+48
-0
admin/dashboard.php
admin/dashboard.php
+1
-0
No files found.
admin/createadmin.php
0 → 100644
View file @
7adb0305
<?php
require
(
'db.php'
);
include
(
"auth.php"
);
$status
=
""
;
if
(
isset
(
$_POST
[
'new'
])
&&
$_POST
[
'new'
]
==
1
)
{
$username
=
$_REQUEST
[
'username'
];
$email
=
$_REQUEST
[
'email'
];
$contactno
=
$_REQUEST
[
'contactno'
];
$clgid
=
$_REQUEST
[
'clgid'
];
$region
=
$_REQUEST
[
'region'
];
$clg
=
$_REQUEST
[
'clg'
];
$state
=
$_REQUEST
[
'state'
];
$password
=
$_REQUEST
[
'password'
];
$ins_query
=
"insert into admins (`username`,`email`,`contactno`,`clgid`,`region`,`clg`,`state`,`password`) values ('
$username
','
$email
','
$contactno
','
$clgid
','
$region
','
$clg
','
$state
','
$password
')"
;
mysqli_query
(
$con
,
$ins_query
)
or
die
(
mysql_error
());
$status
=
"New Record Inserted Successfully.</br></br><a href='view.php'>View Inserted Record</a>"
;
}
?>
<!DOCTYPE html>
<html>
<head>
<meta
charset=
"utf-8"
>
<title>
Insert New Record
</title>
<link
rel=
"stylesheet"
href=
"css/style.css"
/>
</head>
<body>
<div
class=
"form"
>
<div>
<h1>
Create New Admin
</h1>
<form
name=
"form"
method=
"post"
action=
""
>
<input
type=
"hidden"
name=
"new"
value=
"1"
/>
<p><input
type=
"text"
name=
"username"
placeholder=
"Enter Name"
required
/></p>
<p><input
type=
"text"
name=
"email"
placeholder=
"Enter Email Address"
required
/></p>
<p><input
type=
"text"
name=
"contactno"
placeholder=
"Enter Mobile number"
required
/></p>
<p><input
type=
"text"
name=
"clgid"
placeholder=
"Enter Collage id number"
required
/></p>
<p><input
type=
"text"
name=
"region"
placeholder=
"Enter region of admin"
required
/></p>
<p><input
type=
"text"
name=
"clg"
placeholder=
"Enter Collage name present studying"
required
/></p>
<p><input
type=
"text"
name=
"state"
placeholder=
"Enter state"
required
/></p>
<p><input
type=
"text"
name=
"password"
placeholder=
"Enter password"
required
/></p>
<p><input
name=
"submit"
type=
"submit"
value=
"insert"
/></p>
</form>
<p
style=
"color:#FF0000;"
>
<?php
echo
$status
;
?>
</p>
</div>
</div>
</body>
</html>
admin/dashboard.php
View file @
7adb0305
...
...
@@ -18,6 +18,7 @@ include("auth.php"); //include auth.php file on all secure pages ?>
<
p
><
a
href
=
"view1.php"
>
View
Records
of
Requested
and
Donated
person
deatils
</
a
><
p
>
<
p
><
a
href
=
"insertintodonor.php"
>
Donor
and
Blood
Requiested
Person
Details
</
a
></
p
>
<
p
><
a
href
=
"bulkupload.html"
>
To
Bulk
Upload
the
Data
</
a
></
p
>
<
p
><
a
href
=
"createadmin.php"
>
Create
Admin
</
a
></
p
>
<
form
method
=
"POST"
action
=
"filter_search.php"
class
=
"bg-white rounded pb_form_v1"
>
<
div
class
=
"form-group"
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment