Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
KLUGLUG
KL Hostel Outing Automation
Commits
ab81aaf5
Commit
ab81aaf5
authored
Mar 18, 2021
by
Srinivas
Browse files
Update secsec.php
parent
53d12a1e
Changes
1
Show whitespace changes
Inline
Side-by-side
secsec.php
View file @
ab81aaf5
<?php
session_start
();
include
(
'connection.php'
);
$connection
=
getdb
();
?>
<!DOCTYPE html>
<html
lang=
"en-ca"
>
...
...
@@ -174,8 +177,6 @@ if($_SESSION['username4']){
<table>
<?php
$connection
=
mysqli_connect
(
"localhost"
,
"root"
,
""
);
$db
=
mysqli_select_db
(
$connection
,
'test'
);
if
(
isset
(
$_POST
[
'search'
]))
{
...
...
@@ -189,17 +190,16 @@ $password = $_POST['user_pass'];
$cpassword
=
$_POST
[
'user_pass1'
];
if
(
$cpassword
==
$password
){
$conn
=
new
mysqli
(
'localhost'
,
'root'
,
''
,
'test'
);
if
(
$conn
->
connect_error
){
die
(
'Connection Failed : '
.
$conn
->
connect_error
);
if
(
$connection
->
connect_error
){
die
(
'Connection Failed : '
.
$connection
->
connect_error
);
}
else
{
$stmt
=
$conn
->
prepare
(
"insert into security(username,Password)
$stmt
=
$conn
ection
->
prepare
(
"insert into security(username,Password)
values(?,?)"
);
$stmt
->
bind_param
(
"ss"
,
$username
,
$password
);
$stmt
->
execute
();
$stmt
->
close
();
$conn
->
close
();
$conn
ection
->
close
();
}
echo
"<script>location.href='success.php'</script>"
;
}
}
...
...
Write
Preview
Supports
Markdown
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