Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
PA1-1617-D3TI05
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Fredrick Mangampu Theodorus Pardosi
PA1-1617-D3TI05
Commits
351fd025
Commit
351fd025
authored
May 17, 2017
by
Cici
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
upload
parent
74a5442a
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
48 additions
and
0 deletions
+48
-0
upload_bukti.php
upload_bukti.php
+11
-0
upload_bukti_process.php
upload_bukti_process.php
+37
-0
No files found.
upload_bukti.php
0 → 100644
View file @
351fd025
<?php
$id
=
$_GET
[
'id'
];
?>
<form
id=
"contact-us"
method=
"post"
action=
"upload_bukti_process.php?id=
<?=
$id
?>
"
enctype=
"multipart/form-data"
>
<!-- Left Inputs -->
<input
type=
"file"
name=
"uploaded_file"
id=
"username"
required=
"required"
class=
"form"
placeholder=
"Username"
/>
<br><br>
<button
type=
"submit"
id=
"submit"
name=
"submit"
class=
"text-center form-btn form-btn"
>
Upload
</button>
</form>
\ No newline at end of file
upload_bukti_process.php
0 → 100644
View file @
351fd025
<?php
session_start
();
include_once
'functions/fungsi.php'
;
include_once
'connection/koneksi.php'
;
if
(
!
empty
(
$_FILES
[
'uploaded_file'
]))
{
$path
=
"pembayaran/"
;
$path
=
$path
.
basename
(
$_FILES
[
'uploaded_file'
][
'name'
]);
if
(
move_uploaded_file
(
$_FILES
[
'uploaded_file'
][
'tmp_name'
],
$path
))
{
echo
"The file "
.
basename
(
$_FILES
[
'uploaded_file'
][
'name'
])
.
" has been uploaded"
;
}
else
{
echo
"There was an error uploading the file, please try again!"
;
}
}
$gambar
=
basename
(
$_FILES
[
'uploaded_file'
][
'name'
]);
$status
=
"Waiting For Confirmation"
;
$id
=
$_GET
[
'id'
];
//die($gambar);
$sql
=
"UPDATE pembayaran SET status='
$status
',gambar='
$gambar
' WHERE id=
$id
"
;
if
(
$database
->
query
(
$sql
)
===
TRUE
)
{
echo
"Record updated successfully"
;
}
else
{
echo
"Error updating record: "
.
$database
->
error
;
}
redirect
(
'index.php#pembayaran'
);
?>
\ No newline at end of file
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