Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
TB_Center
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
Andry F. Hutapea
TB_Center
Commits
6e110e2f
Commit
6e110e2f
authored
May 25, 2017
by
Loni Miranda Doloksaribu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
In Progress
parent
cd50727b
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
70 additions
and
0 deletions
+70
-0
daftar_pesanan.php
daftar_pesanan.php
+70
-0
No files found.
daftar_pesanan.php
0 → 100644
View file @
6e110e2f
<?php
$host
=
"localhost"
;
// Host name
$username
=
"root"
;
// Mysql username
$password
=
""
;
// Mysql password
$db_name
=
"tbc"
;
// Database name
$tbl_name
=
"fpemesanan"
;
// Table name
// Connect to server and select databse.
$conn
=
mysqli_connect
(
"
$host
"
,
"
$username
"
,
"
$password
"
)
or
die
(
"cannot connect"
);
mysqli_select_db
(
$conn
,
"
$db_name
"
)
or
die
(
"cannot select DB"
);
$sql
=
"SELECT * FROM
$tbl_name
ORDER BY id DESC"
;
// OREDER BY id DESC is order result by descending
$result
=
mysqli_query
(
$conn
,
$sql
);
$no
=
0
;
?>
<table
width=
"90%"
border=
"0"
align=
"center"
cellpadding=
"3"
cellspacing=
"1"
bgcolor=
"#CCCCCC"
>
<tr>
<td
width=
"10%"
align=
"center"
bgcolor=
"#E6E6E6"
><strong>
No
</strong></td>
<td
width=
"10%"
align=
"center"
bgcolor=
"#E6E6E6"
><strong>
Jumlah Pesanan
</strong></td>
<td
width=
"15%"
align=
"center"
bgcolor=
"#E6E6E6"
><strong>
Nama Pemesan
</strong></td>
<td
width=
"15%"
align=
"center"
bgcolor=
"#E6E6E6"
><strong>
Kategori
</strong></td>
<td
width=
"13%"
align=
"center"
bgcolor=
"#E6E6E6"
><strong>
Replies
</strong></td>
<td
width=
"13%"
align=
"center"
bgcolor=
"#E6E6E6"
><strong>
Date/Time
</strong></td>
</tr>
<?php
// Start looping table row
while
(
$rows
=
mysqli_fetch_array
(
$result
)){
?>
<tr>
<td
align=
"center"
bgcolor=
"#FFFFFF"
>
<?php
echo
++
$no
;;
?>
</td>
<td
align=
"center"
bgcolor=
"#FFFFFF"
><a
href=
"view_pemesanan.php?id=
<?php
echo
$rows
[
'id'
];
?>
"
>
<?php
echo
$rows
[
'topic'
];
?>
</a><BR></td>
<td
align=
"center"
bgcolor=
"#FFFFFF"
>
<?php
echo
$rows
[
'name'
];
?>
</td>
<td
align=
"center"
bgcolor=
"#FFFFFF"
>
<?php
echo
$rows
[
'detail'
];
?>
</td>
<td
align=
"center"
bgcolor=
"#FFFFFF"
>
<?php
echo
$rows
[
'reply'
];
?>
</td>
<td
align=
"center"
bgcolor=
"#FFFFFF"
>
<?php
echo
$rows
[
'datetime'
];
?>
</td>
</tr>
<?php
// Exit looping and close connection
}
//mysql_close();
?>
<tr>
<td
colspan=
"5"
align=
"right"
bgcolor=
"#E6E6E6"
><a
href=
"booking.php"
><strong>
Pesan Tiket
</strong>
</a></td>
</tr>
</table>
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