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
e0a9997b
Commit
e0a9997b
authored
Mar 18, 2021
by
Srinivas
Browse files
Update success22.php
parent
16baf53e
Pipeline
#37747
failed with stage
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
success22.php
View file @
e0a9997b
<?php
session_start
();
include
(
'connection.php'
);
$connection
=
getdb
();
?>
<!DOCTYPE html>
...
...
@@ -152,8 +155,6 @@ window.onload = function(){
<?php
$x
=
$_GET
[
'id'
];
$connection
=
mysqli_connect
(
"localhost"
,
"root"
,
""
);
$db
=
mysqli_select_db
(
$connection
,
'test'
);
$query
=
"SELECT * FROM student where ID='
$x
' "
;
$query_run
=
mysqli_query
(
$connection
,
$query
);
?>
...
...
@@ -191,17 +192,16 @@ $status='applied';
date_default_timezone_set
(
'Asia/Kolkata'
);
$date
=
date
(
'y-m-d H:i:s'
);
$AppliedDateTime
=
$date
;
$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 registrations(ID,NAME,ROOM,PHONE,TYPE,LeavingDate,status,AppliedDateTime,HostelName,reason)
$stmt
=
$conn
ection
->
prepare
(
"insert into registrations(ID,NAME,ROOM,PHONE,TYPE,LeavingDate,status,AppliedDateTime,HostelName,reason)
values(?,?,?,?,?,?,?,?,?,?)"
);
$stmt
->
bind_param
(
"ississssss"
,
$ID
,
$NAME
,
$ROOM
,
$PHONE
,
$TYPE
,
$LeavingDate
,
$status
,
$AppliedDateTime
,
$HostelName
,
$reason
);
$stmt
->
execute
();
$stmt
->
close
();
$conn
->
close
();
$conn
ection
->
close
();
}
?>
<div
class=
"main1"
>
...
...
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