Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
RestoranPondokEdo
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
Mei Romauli Sagala
RestoranPondokEdo
Commits
424a1f0d
Commit
424a1f0d
authored
May 22, 2017
by
Roy Junedi Simamora
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
perbaikan form daftar
parent
865fa461
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
7 deletions
+13
-7
cek_daftar.php
cek_daftar.php
+12
-7
form_daftar.php
form_daftar.php
+1
-0
No files found.
cek_daftar.php
View file @
424a1f0d
<?php
<?php
include
(
'koneksi.php'
);
include
(
'koneksi.php'
);
include
'common/header.php'
;
//menginisiasi variabel-variabel yang dikirimkan dari form-->input name
//menginisiasi variabel-variabel yang dikirimkan dari form-->input name
//fix problem : undefined index...
//fix problem : undefined index...
...
@@ -36,17 +37,20 @@
...
@@ -36,17 +37,20 @@
if
(
$cek_username
==
0
){
//jika nama tidak ditemukan/belum terdaftar
if
(
$cek_username
==
0
){
//jika nama tidak ditemukan/belum terdaftar
//lakukan penambahan data
//lakukan penambahan data
$id
=
$countData
+
1
;
$id
=
$countData
+
1
;
mysqli_query
(
$GLOBALS
[
"___mysqli_ston"
],
"INSERT INTO member VALUES(
$id
,'
$nama
','
$address
','
$hp
','
$uname
','
$pass
','
$email
')"
);
mysqli_query
(
$GLOBALS
[
"___mysqli_ston"
],
"INSERT INTO member VALUES(
'
$id
','
$nama
','
$address
','
$hp
','
$uname
','
$pass
','
$email
', '1
')"
);
echo
"<div class='alert'> <h2> Pendaftaran Berhasil </h2> </div>"
;
echo
"pendaftaran berhasil
"
;
echo
"<a href='form_daftar.php' class='btn btn-primary'> <span class='glyphicon glyphicon-chevron-left'></span> Kembali </a>
"
;
}
else
{
}
else
{
echo
"<h2> username pengguna sudah terdaftar. Silahkan ganti username anda</h2>"
;
echo
"<h2> username pengguna sudah terdaftar. Silahkan ganti username anda</h2>"
;
echo
"<a href='form_daftar.php'>Kembali ke halaman pendaftaran</a>"
;
echo
"<a href='form_daftar.php'
class='btn btn-info'
>Kembali ke halaman pendaftaran</a>"
;
}
}
}
else
{
}
else
{
//jika kata sandi tidak sama
//jika kata sandi tidak sama
echo
"
kata sandi tidak sama
"
;
echo
"
<h2>Kata Sandi Tidak Cocok</h2>
"
;
echo
"<a href='pendaftaran.php'>Kembali ke halaman pendaftaran
</a>"
;
echo
"<a href='form_daftar.php' class='btn btn-info'>Kembali
</a>"
;
}
}
echo
'<br/> <br/>'
;
include
'common/footer.php'
;
?>
?>
\ No newline at end of file
form_daftar.php
View file @
424a1f0d
...
@@ -2,6 +2,7 @@
...
@@ -2,6 +2,7 @@
require_once
(
dirname
(
__FILE__
)
.
'/koneksi.php'
);
require_once
(
dirname
(
__FILE__
)
.
'/koneksi.php'
);
require_once
(
dirname
(
__FILE__
)
.
'/common/header.php'
);
require_once
(
dirname
(
__FILE__
)
.
'/common/header.php'
);
?>
?>
<br/>
<form
class=
"well form-horizontal"
action=
"cek_daftar.php"
method=
"post"
id=
"contact_form"
>
<form
class=
"well form-horizontal"
action=
"cek_daftar.php"
method=
"post"
id=
"contact_form"
>
<fieldset>
<fieldset>
<legend>
Member Registration
</legend>
<legend>
Member Registration
</legend>
...
...
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