35
36
Lampiran 2 Halaman Utama
37
Lampiran 4 Halaman Customer
38
Lampiran 6 Halaman Sales
39
Lampiran 8 Halaman Tentang Kami
40
Lampiran 10 : Kode Aplikasi
About.PHP<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php" class="current">Beranda</a></li> <li><a href="products.php" target="_parent">Login</a></li> <li><a href="gallery.php"
target="_parent">Galeri</a></li> <li><a href="services.php"
target="_parent">Pelayanan</a></li>
<li><a href="about.php">Tentang Kami</a></li> <li><a href="contact.php">Hubungi Kami</a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<div class="cleaner_with_height"> </div> <h2>About Us</h2>
41
include('db.php');
$result = mysql_query("SELECT * FROM about");
while($row=mysql_fetch_assoc($result)) {
echo
'<div class="product_box"> <h3>'.$row['About'].'<br> </h3>
<p>'.$row['Info'].'<br> </p>
</div>';
} ?>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Categories</h4>
<div class="templatemo_right_section_content"> <ul>
<?php
include('category.php'); ?>
</ul> </div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<!-- Free CSS Template | Designed by TemplateMo.com --> <div align="center"><br>
</div> </body> </html>
Addexec.php <?php
include('db.php'); $prod = $_POST['prod']; $desc = $_POST['desc']; $cat = $_POST['cat']; $price = $_POST['price'];
mysql_query("INSERT INTO products (Product,Description,Category,Price) VALUES('$prod','$desc','$cat','$price')");
header("location: admin.php"); exit();
?>
Addtocart.php <?php
include('db.php');
42
mysql_query("INSERT INTO cart (Product,Price) VALUES('$Product','$Price')");
header("location: cart.php"); exit();
?>
Admin.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php">Keluar</a></li>
<li><a href="admin.php" class="current">Produk</a></li> <li><a href="users.php"
target="_parent">User</a></li> <li><a href="orders.php"
target="_parent">Pemesanan</a></li> <li><a href="about.php"></a></li> <li><a href="contact.php"></a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<div class="cleaner_with_height"> </div> <h2>Daftar Produk</h2>
<?php
include('db.php');
$result = mysql_query("SELECT * FROM Products");
echo'<table border=1">
<th>Id</th><th>Produk</th><th>Deskripsi</th><td>Kategori</td> <th>Harga</th><th>Aksi</th>';
while($row=mysql_fetch_assoc($result)) {
echo '<tr>
<td>'.$row['ID'].'</td> <td>'.$row['Product'].'</td> <td>'.$row['Description'].'</td> <td>'.$row['Category'].'</td> <td>'.$row['Price'].'</td>
<td><a href="deleteorder.php?ID='.$row['ID'].'">Hapus</a></td> </tr>';
}
echo '</table>';
?>
<br><hr><br>
<h2>Tambah Produk Baru</h2>
<form action="addexec.php" method="post" style="margin-bottom:none;"> <table>
<tr>
<td>Nama Produk : </td><td><input type="text" id="prod" name="prod"/></td> </tr>
<tr>
43
</tr> <tr>
<td>Kategori : </td><td><input type="text" id="cat" name="cat"/></td> </tr>
<tr>
<td>Harga : </td><td><input type="text" id="price" name="price"/></td> </tr>
<tr>
<td></td><td><input type="reset" /><input type="submit" /></td> </tr>
</table>
</form>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Categories</h4>
<div class="templatemo_right_section_content"> <ul>
<?php
include('category.php'); ?>
</ul> </div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<!-- Free CSS Template | Designed by TemplateMo.com --> <div align="center"><br>
</div> </body> </html>
Cart.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatexe Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
44
target="_parent">Produk</a></li> <li><a class="current" href="cart.php" target="_parent">Keranjang</a></li> <li><a href="services.php"></a></li> <li><a href="about.php"></a></li> <li><a href="contact.php"></a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<div class="cleaner_with_height"> </div> <h2>Daftar Keranjang</h2>
<form method="POST" action="order.php" > <?php
include('db.php');
$currentuser = mysql_query("SELECT * FROM currentuser"); while($urow=mysql_fetch_assoc($currentuser))
{
echo 'Nama Lengkap : '.$urow['Realname'].' </br/>'; echo 'No.telp : '.$urow['Contact'].'</br/>'; echo 'Alamat : '.$urow['Address'].'</br/>'; echo 'Email : '.$urow['Email'].'</br/>'; }
$result = mysql_query("SELECT * FROM cart");
echo'<br><hr><br><table border=1 width="100%">
<th>Id</th><th>Produk</th><th>Harga</th><th>Ukuran/yds</th><th>Aksi</th>'; $id=1;
while($row=mysql_fetch_assoc($result)) {
echo '<tr>
<td width="40" align="center">'.$id.'</td> <td>'.$row['Product'].'</td>
<td align="right" width="100"><input type="textbox" readonly=readonly
value="'.$row['Price'].'" id="p'.$row['ID'].'" name="p'.$row['ID'].'"/></td> <td align="right" width="100"><input type="textbox" value="'.$row['itemsize'].'" id="s'.$row['ID'].'" name="s'.$row['ID'].'"/></td>
<td width="80" align="center"><a href="deletecart.php?ID='.$row['ID'].'">Hapus</a></td> </tr>';
$id++; }
echo '</table><br><br>';
echo '<a href="clearcart.php">Hapus Keranjang</a>';
?>
<input type="submit" /> </form>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Categories</h4>
<div class="templatemo_right_section_content"> <ul>
<?php
include('category.php'); ?>
</ul> </div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
45
<div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<!-- Free CSS Template | Designed by TemplateMo.com --> <div align="center"><br>
</div> </body> </html>
Category.php
<li><a href="kain1.php">Kain Satin</a></li> <li><a href="kain2.php">Kain katun</a></li> <li><a href="kain3.php">Kain wools</a></li> <li><a href="kain4.php">Kain sutra</a></li> <li><a href="kain5.php">Kain denin</a></li>
Clearcart.php <?php
include('db.php');
mysql_query("DELETE FROM cart"); header("location: cart.php"); exit();
?>
Contact.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php" class="current">Beranda</a></li> <li><a href="products.php" target="_parent">Login</a></li> <li><a href="gallery.php"
target="_parent">Galeri</a></li> <li><a href="services.php"
target="_parent">Pelayanan</a></li>
<li><a href="about.php">Tentang Kami</a></li> <li><a href="contact.php">Hubungi Kami</a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<div class="cleaner_with_height"> </div> <h2>Contact Us</h2>
<?php
include('db.php');
$result = mysql_query("SELECT * FROM contact");
46
{ echo
'<div class="product_box"> <h3>'.$row['Contact'].'<br> </h3>
<p>'.$row['Info'].'<br> </p>
</div>';
} ?>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Categories</h4>
<div class="templatemo_right_section_content"> <ul>
<?php
include('category.php'); ?>
</ul> </div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<!-- Free CSS Template | Designed by TemplateMo.com --> <div align="center"><br>
</div> </body> </html>
Db.php <?php
$mysql_hostname = "localhost"; $mysql_user = "root";
$mysql_password = ""; $mysql_database = "shop"; $prefix = "";
$bd = mysql_connect($mysql_hostname, $mysql_user, $mysql_password) or die("Could not connect database");
mysql_select_db($mysql_database, $bd) or die("Could not select database"); ?>
Deletecart.php <?php
include('db.php'); $ID=$_GET['ID'];
mysql_query("DELETE FROM cart WHERE ID = $ID"); header("location: cart.php");
exit(); ?>
Deleteorder.php <?php
include('db.php'); $ID=$_GET['ID'];
47
header("location: orders.php"); exit();
?>
Footer.php
<div id="footer_right"> Copyright © 2015 Timatex Shop<a href="#"></a><br>
</div>
<div class="cleaner"> </div>
Gallery.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php" class="current">Beranda</a></li> <li><a href="products.php" target="_parent">Login</a></li> <li><a href="gallery.php"
target="_parent">Galeri</a></li> <li><a href="services.php"
target="_parent">Pelayanan</a></li>
<li><a href="about.php">Tentang Kami</a></li> <li><a href="contact.php">Hubungi Kami</a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<div class="cleaner_with_height"> </div> <h2>Gallery</h2>
<?php
include('db.php');
if(isset($_POST['filter'])) {
$filter = $_POST['filter'];
$result = mysql_query("SELECT * FROM products where Category ='$filter'"); }
else {
$result = mysql_query("SELECT * FROM products"); }
while($row=mysql_fetch_assoc($result)) {
echo
'<div class="product_box"> <h3>'.$row['Product'].'<br> </h3>
<img src="images/products/'.$row['ID'].'.jpg" width="200" height="150" alt="image"> </div>';
} ?>
<div class="cleaner_with_height"> </div> </div>
48
<div class="templatemo_right_section"> <h4>Categories</h4>
<div class="templatemo_right_section_content"> <ul>
<?php
include('category.php'); ?>
</ul> </div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<!-- Free CSS Template | Designed by TemplateMo.com --> <div align="center"><br>
</div> </body> </html>
Index.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php" class="current">Beranda</a></li> <li><a href="products.php" target="_parent">Login</a></li> <li><a href="gallery.php"
target="_parent">Galeri</a></li> <li><a href="services.php"
target="_parent">Pelayanan</a></li>
<li><a href="about.php">Tentang Kami</a></li> <li><a href="contact.php">Hubungi Kami</a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<h1>Selamat datang di Timatex shop <br> </h1>
Selamat berbelanja dengan berbagai produk unggulan kami <br> <div class="cleaner_with_height"> </div>
49
<?php
include('db.php');
$result = mysql_query("SELECT * FROM products");
while($row=mysql_fetch_assoc($result)) {
echo
'<div class="product_box"> <h3>'.$row['Product'].'<br> </h3>
<img width="200" height="150" src="images/products/'.$row['ID'].'.jpg" alt="image"> <p>'.$row['Description'].'<br>
</p>
<div class="price">PRICE:<span> '.$row['Price'].'</span></div> <div class="buynow"><a href="products.php">Beli</a></div> </div>';
} ?>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Pengiriman dan Pembayaran</h4>
<div class="templatemo_right_section_content"> Untuk pembayaran bisa lewat no.rek dibawah ini: <h><br>
324501008137559 A/N. timonshop. pengiriman via : JNE
</div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<div align="center"><br> </div>
</body> </html>
Kain1.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
50
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php" class="current">Beranda</a></li>
<li><a href="products.php" target="_parent">Produk kami</a></li> <li><a href="gallery.php"
target="_parent">Galeri</a></li> <li><a href="services.php"
target="_parent">Pelayanan</a></li>
<li><a href="about.php">Tentang Kami</a></li> <li><a href="contact.php">Hubungi Kami</a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<h1>Selamat datang di Timatex shop <br> </h1>
Selamat berbelanja dengan berbagai produk unggulan kami <br> <div class="cleaner_with_height"> </div>
<h2>Produk Kami</h2>
<?php
include('db.php');
$result = mysql_query("SELECT * FROM products where Category = 'kain satin'");
while($row=mysql_fetch_assoc($result)) {
echo
'<div class="product_box"> <h3>'.$row['Product'].'<br> </h3>
<img width="200" height="150" src="images/products/'.$row['ID'].'.jpg" alt="image"> <p>'.$row['Description'].'<br>
</p>
<div class="price">PRICE:<span> '.$row['Price'].'</span></div> <div class="buynow"><a href="products.php">Beli</a></div> </div>';
} ?>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Pengiriman dan Pembayaran</h4>
<div class="templatemo_right_section_content"> Untuk pembayaran bisa lewat no.rek dibawah ini: <h><br>
324501008137559 A/N timonshop. pengiriman via : JNE
</div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
51
</div>
<div align="center"><br> </div>
</body> </html>
Kain2.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php" class="current">Beranda</a></li>
<li><a href="products.php" target="_parent">Produk kami</a></li> <li><a href="gallery.php"
target="_parent">Galeri</a></li> <li><a href="services.php"
target="_parent">Pelayanan</a></li>
<li><a href="about.php">Tentang Kami</a></li> <li><a href="contact.php">Hubungi Kami</a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<h1>Selamat datang di Timatex shop <br> </h1>
Selamat berbelanja dengan berbagai produk unggulan kami <br> <div class="cleaner_with_height"> </div>
<h2>Produk Kami</h2>
<?php
include('db.php');
$result = mysql_query("SELECT * FROM products where Category = 'kain katun'");
while($row=mysql_fetch_assoc($result)) {
echo
'<div class="product_box"> <h3>'.$row['Product'].'<br> </h3>
<img width="200" height="150" src="images/products/'.$row['ID'].'.jpg" alt="image"> <p>'.$row['Description'].'<br>
</p>
<div class="price">PRICE:<span> '.$row['Price'].'</span></div> <div class="buynow"><a href="products.php">Beli</a></div> </div>';
} ?>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Pengiriman dan Pembayaran</h4>
52
Untuk pembayaran bisa lewat no.rek dibawah ini: <h><br>
324501008137559 A/N timonshop. pengiriman via : JNE
</div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<div align="center"><br> </div>
</body> </html>
Kain3.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php" class="current">Beranda</a></li>
<li><a href="products.php" target="_parent">Produk kami</a></li> <li><a href="gallery.php"
target="_parent">Galeri</a></li> <li><a href="services.php"
target="_parent">Pelayanan</a></li>
<li><a href="about.php">Tentang Kami</a></li> <li><a href="contact.php">Hubungi Kami</a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<h1>Selamat datang di Timatex shop <br> </h1>
Selamat berbelanja dengan berbagai produk unggulan kami <br> <div class="cleaner_with_height"> </div>
<h2>Produk Kami</h2>
<?php
include('db.php');
53
while($row=mysql_fetch_assoc($result)) {
echo
'<div class="product_box"> <h3>'.$row['Product'].'<br> </h3>
<img width="200" height="150" src="images/products/'.$row['ID'].'.jpg" alt="image"> <p>'.$row['Description'].'<br>
</p>
<div class="price">PRICE:<span> '.$row['Price'].'</span></div> <div class="buynow"><a href="products.php">Beli</a></div> </div>';
} ?>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Pengiriman dan Pembayaran</h4>
<div class="templatemo_right_section_content"> Untuk pembayaran bisa lewat no.rek dibawah ini: <h><br>
324501008137559 A/N timonshop. pengiriman via : JNE
</div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<div align="center"><br> </div>
</body> </html>
Kain4.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
54
<li><a href="index.php" class="current">Beranda</a></li>
<li><a href="products.php" target="_parent">Produk kami</a></li> <li><a href="gallery.php"
target="_parent">Galeri</a></li> <li><a href="services.php"
target="_parent">Pelayanan</a></li>
<li><a href="about.php">Tentang Kami</a></li> <li><a href="contact.php">Hubungi Kami</a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<h1>Selamat datang di Timatex shop <br> </h1>
Selamat berbelanja dengan berbagai produk unggulan kami <br> <div class="cleaner_with_height"> </div>
<h2>Produk Kami</h2>
<?php
include('db.php');
$result = mysql_query("SELECT * FROM products where Category = 'kain sutra'");
while($row=mysql_fetch_assoc($result)) {
echo
'<div class="product_box"> <h3>'.$row['Product'].'<br> </h3>
<img width="200" height="150" src="images/products/'.$row['ID'].'.jpg" alt="image"> <p>'.$row['Description'].'<br>
</p>
<div class="price">PRICE:<span> '.$row['Price'].'</span></div> <div class="buynow"><a href="products.php">Beli</a></div> </div>';
} ?>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Pengiriman dan Pembayaran</h4>
<div class="templatemo_right_section_content"> Untuk pembayaran bisa lewat no.rek dibawah ini: <h><br>
324501008137559 A/N timonshop. pengiriman via : JNE
</div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<div align="center"><br> </div>
55
</html>
Kain5.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php" class="current">Beranda</a></li>
<li><a href="products.php" target="_parent">Produk kami</a></li> <li><a href="gallery.php"
target="_parent">Galeri</a></li> <li><a href="services.php"
target="_parent">Pelayanan</a></li>
<li><a href="about.php">Tentang Kami</a></li> <li><a href="contact.php">Hubungi Kami</a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<h1>Selamat datang di Timatex shop <br> </h1>
Selamat berbelanja dengan berbagai produk unggulan kami <br> <div class="cleaner_with_height"> </div>
<h2>Produk Kami</h2>
<?php
include('db.php');
$result = mysql_query("SELECT * FROM products where Category = 'kain denin'");
while($row=mysql_fetch_assoc($result)) {
echo
'<div class="product_box"> <h3>'.$row['Product'].'<br> </h3>
<img width="200" height="150" src="images/products/'.$row['ID'].'.jpg" alt="image"> <p>'.$row['Description'].'<br>
</p>
<div class="price">PRICE:<span> '.$row['Price'].'</span></div> <div class="buynow"><a href="products.php">Beli</a></div> </div>';
} ?>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Pengiriman dan Pembayaran</h4>
<div class="templatemo_right_section_content"> Untuk pembayaran bisa lewat no.rek dibawah ini: <h><br>
324501008137559 A/N timonshop. pengiriman via : JNE
56
</div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<div align="center"><br> </div>
</body> </html>
Keranjang.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php">Keluar</a></li> <li><a href="productsuser.php"
target="_parent">Produk</a></li> <li><a class="current" href="cart.php" target="_parent">Keranjang</a></li> <li><a href="services.php"></a></li> <li><a href="about.php"></a></li> <li><a href="contact.php"></a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<div class="cleaner_with_height"> </div> <h2>Daftar Keranjang</h2>
<form method="POST" action="order.php" > <?php
include('db.php');
$currentuser = mysql_query("SELECT * FROM currentuser"); while($urow=mysql_fetch_assoc($currentuser))
{
$cs =$urow['Realname']; echo $cs;
57
?>
<?php
$result = mysql_query("SELECT * FROM Orders where Customer = '$cs'");
echo'<br><hr><br><table border=1 width="100%">
<th>Id</th><th>Produk</th><th>Harga</th><th>Ukuran/yds</th>'; $id=1;
$total= 0; $ttotal= 0;
while($row=mysql_fetch_array($result)) { $harga = $row['Total'];
$ukuran = $row['size']; $totaltemp= $ttotal; $total = $harga * $ukuran;
$ttotal = $total + $totaltemp; echo '<tr>
<td width="40" align="center">'.$id.'</td> <td>'.$row['Product'].'</td>
<td align="right" width="100"> '.$row['Total'].' </td> <td align="right" width="100"> '.$row['size'].' </td>
</tr>'; $id++; }
echo'<th>Total</th><th></th><th></th><th>'; echo $ttotal ;
echo'</th>';
echo '</table><br><br>';
?>
<?php } ?>
</form>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Categories</h4>
<div class="templatemo_right_section_content"> <ul>
<?php
include('category.php'); ?>
</ul> </div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<!-- Free CSS Template | Designed by TemplateMo.com --> <div align="center"><br>
58
Login.php <?php
//Start session session_start();
//Connect to mysql server require "db.php";
//Function to sanitize values received from the form. Prevents SQL injection function clean($str) {
$str = @trim($str);
if(get_magic_quotes_gpc()) { $str = stripslashes($str); }
return mysql_real_escape_string($str); }
//Sanitize the POST values $login = clean($_POST['user']);
$password = clean($_POST['password']);
//Create query
$qry1="SELECT * FROM users WHERE username='$login' AND password='$password' AND Role='Administrator'";
$result1=mysql_query($qry1);
//Check whether the query was successful or not if($result1) {
if(mysql_num_rows($result1) > 0) { //Login Successful
session_regenerate_id();
$member1 = mysql_fetch_assoc($result);
mysql_query("UPDATE currentuser SET Email='".$member1['Email']."',
Realname='".$member1['Realname']."',Contact='".$member1['Contact']."',Address='".$member1['Add ress']."'");
session_write_close();
header("location: admin.php");
exit();
} }else {
die("Query failed"); }
$qry="SELECT * FROM users WHERE username='$login' AND password='$password'"; $result=mysql_query($qry);
//Check whether the query was successful or not if($result) {
if(mysql_num_rows($result) > 0) { //Login Successful
mysql_query("DELETE FROM cart"); session_regenerate_id();
$member = mysql_fetch_assoc($result);
mysql_query("UPDATE currentuser SET Email='".$member['Email']."',
Realname='".$member['Realname']."',Contact='".$member['Contact']."',Address='".$member['Addres s']."'");
session_write_close();
header("location: productsuser.php");
exit(); }else { //Login failed
header("location: products.php"); exit();
} }else {
die("Query failed"); }
?>
Order.php <?php
59
$currentuser = mysql_query("SELECT * FROM currentuser"); while($urow=mysql_fetch_assoc($currentuser))
{
$CName=$urow['Realname']; $Contact=$urow['Contact']; $Address=$urow['Address']; $Email=$urow['Email']; }
$result=mysql_query("SELECT * FROM cart"); while($row=mysql_fetch_assoc($result)) {
$Prod = $row['Product'];
$ItemCount = $_POST['t'.$row['ID'].'']; $itemsize = $_POST['s'.$row['ID'].'']; $Price = $_POST['p'.$row['ID'].''];
mysql_query("INSERT INTO orders (Customer,Product,Count,Total,size,Address,OrderDate) VALUES('$CName','$Prod','$ItemCount','$Price','$itemsize','$Address',now())"); }
mysql_query("DELETE FROM cart"); header("location: keranjang.php"); exit();
?>
Product.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php" class="current">Beranda</a></li> <li><a href="products.php" target="_parent">Login</a></li> <li><a href="gallery.php"
target="_parent">Galeri</a></li> <li><a href="services.php"
target="_parent">Pelayanan</a></li>
<li><a href="about.php">Tentang Kami</a></li> <li><a href="contact.php">Hubungi Kami</a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<div class="cleaner_with_height"> </div> <h2>Login</h2>
<form action="login.php" method="post" style="margin-bottom:none;">
<span style="margin-right: 11px;">Username: <input type="text" name="user" style="width: 165px; margin-left: 15px; border: 3px double #CCCCCC; padding:5px 10px;"/></span><br> <span style="margin-right: 11px;">Password: <input type="password" name="password" style="width: 165px; margin-left: 15px; border: 3px double #CCCCCC; padding:5px 10px;"/></span><br><br>
<input type="submit" id="submit" value="login" style="height: 34px; margin-left: 15px; width: 191px; padding: 5px; border: 3px double rgb(204, 204, 204);" />
</form> <hr>
60
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Categories</h4>
<div class="templatemo_right_section_content"> <ul>
<?php
include('category.php'); ?>
</ul> </div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<!-- Free CSS Template | Designed by TemplateMo.com --> <div align="center"><br>
</div> </body> </html> Regexec.php <?php
include('db.php'); $uName = $_POST['uName']; $pWord = $_POST['pWord']; $rName = $_POST['rName']; $Contact = $_POST['cNum']; $Address = $_POST['addr']; $Email = $_POST['email'];
mysql_query("INSERT INTO users (Username,Password,Realname,Contact,Address,Email,Role) VALUES('$uName','$pWord','$rName','$Contact','$Address','$Email','User')");
header("location: products.php"); exit();
?>
Register.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php" class="current">Beranda</a></li>
61
<li><a href="gallery.php"
target="_parent">Galeri</a></li> <li><a href="services.php"
target="_parent">Pelayanan</a></li>
<li><a href="about.php">Tentang Kami</a></li> <li><a href="contact.php">Hubungi Kami</a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<div class="cleaner_with_height"> </div> <h2>Login</h2>
<form action="regexec.php" method="post" style="margin-bottom:none;"> <table>
<tr>
<td>Username: </td><td><input type="text" id="uName" name="uName"/></td> </tr>
<tr>
<td>Password: </td><td><input type="password" id="pWord" name="pWord"/></td> </tr>
<tr>
<td>Nama Lengkat: </td><td><input type="text" id="rName" name="rName"/></td> </tr>
<tr>
<td>No. telp: </td><td><input type="text" id="cNum" name="cNum"/></td> </tr>
<tr>
<td>Alamat: </td><td><input type="text" id="addr" name="addr"/></td> </tr>
<tr>
<td>Email: </td><td><input type="text" id="email" name="email" /></td> </tr>
<tr>
<td></td><td><input type="reset" /><input type="submit" /></td> </tr>
</table>
</form>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Categories</h4>
<div class="templatemo_right_section_content"> <ul>
<?php
include('category.php'); ?>
</ul> </div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<!-- Free CSS Template | Designed by TemplateMo.com --> <div align="center"><br>
62
</body> </html>
Services.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header">
<img src="images/logo.jpg"/> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6>
</div>
<div id="menu_panel"> <ul>
<li><a href="index.php" class="current">Beranda</a></li> <li><a href="products.php" target="_parent">Login</a></li> <li><a href="gallery.php"
target="_parent">Galeri</a></li> <li><a href="services.php"
target="_parent">Pelayanan</a></li>
<li><a href="about.php">Tentang Kami</a></li> <li><a href="contact.php">Hubungi Kami</a></li> </ul>
</div>
<!-- end of menu --> <div id="content"> <div id="content_left">
<div class="cleaner_with_height"> </div> <h2>Offered Services</h2>
<?php
include('db.php');
$result = mysql_query("SELECT * FROM services");
while($row=mysql_fetch_assoc($result)) {
echo
'<div class="product_box"> <h3>'.$row['Service'].'<br> </h3>
<p>'.$row['Description'].'<br> </p>
</div>';
} ?>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Categories</h4>
<div class="templatemo_right_section_content"> <ul>
<?php
include('category.php'); ?>
</ul> </div> </div>
63
<h4><br> </h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<!-- Free CSS Template | Designed by TemplateMo.com --> <div align="center"><br>
</div> </body> </html>
Style.php /*
CSS Credit: http://www.templatemo.com/ */
body { margin: 0; padding: 0;
line-height: 1.5em;
font-family: Verdana, Arial, san-serif; font-size: 11px;
color: #fff;
background-image:url(images/image001.png); }
h5 {
font-size: 34pt;
font-style: italic; margin: 0;
margin-top: 100px; }
h6{
font-size: 9pt; margin-left: 134px; }
a:link, a:visited { color: #F1A5D5; text-decoration: underline; } a:active, a:hover { color: #BBBBBB; text-decoration:none; }
h1 {
margin: 0px;
padding: 10px 0 20px 0; font-size: 24px;
color: #ffffff; font-weight: normal; }
h2 {
margin: 0 0 20px 0; padding: 10px 0 10px 15px; font-size: 24px;
color: #ffffff; font-weight: normal; background-color: #4BA887; }
h3 {
margin: 0 0 10px 0; padding: 5px 0 5px 10px; font-size: 16px;
64
}
h4 { margin: 0;
padding: 5px 0 5px 15px; font-size: 16px;
color: #ffffff; font-weight: normal; background-color: #4BA887; }
p {
margin: 0px;
padding: 0 0 10px 0; text-align: justify; }
.price{
font-size:16px; margin-bottom: 10px; }
.price span{ font-size:16px; color: #ffffff; }
.buynow a{ clear: both; display: block; float: left; width: 80px; padding: 1px 0;
margin: 0 15px 10px 0; text-align: center; font-weight: bold; text-decoration: none; color: #377962;
background: #FFFFFF;
border-bottom: 3px solid #C0C0C0; }
.cleaner { clear: both; width: 100%; height: 1px; font-size: 1px; }
.cleaner_with_height { clear: both;
width: 100%; height: 30px; font-size: 1px; }
#container{ width: 940px; margin: 0 auto;
border: 10px solid #4BA887; }
/* top panel */ #top_panel { overflow: hidden; width: 880px; height: 32px; padding: 5px 30px; background: #c82c74;
border-bottom: 1px solid #870843; }
#top_panel #language_section { float: left;
65
padding: 0; }
#top_panel #language_section img { padding: 0px;
border: none; margin-right: 5px;
border: 1px solid #ffffff; }
#top_panel #shopping_cart { float: right;
width: 400px; padding-top: 10px; text-align: right; font-size: 14px; font-weight: bold; color: #ffffff; }
#top_panel #shopping_cart span{ font-weight: normal;
}
/* end of top panel */
/* header panel */ #container #header { overflow: hidden; width: 900px; height: 250px; padding-left: 43px;
background-color: rgb(82, 199, 167);
}
#container #header img{ width: 16%;
float: left; margin-top: 55px; margin-right: 20px; }
/* end of header panel */
/* header panel */ #container #banner { overflow: hidden; width: 880px;
height: 190px; /* + 60 for padding top and bottom */ padding: 30px 30px;
background: #ffffff url(images/templatemo_banner_bg.jpg) top right no-repeat; }
/* end of header panel */
/* menu */ #menu_panel{ overflow: hidden; width: 880px; height: 40px; padding: 0 30px; background: #4BA887; }
#menu_panel ul { float: left; width: 930px; margin: 0;
padding: 5px 0 0 0; list-style: none; }
#menu_panel ul li{ display: inline; }
#menu_panel ul li a{ float: left;
66
padding: 5px 0; font-size: 12px; font-weight: bold; text-align: center; text-decoration: none; color: #FFFFFF;
border-left: 1px solid #FFFFFF; }
#menu_panel li a:hover, #menu_panel li .current{ color: #ffffff;
}
/* end of menu */
/* content */ #content{ width: 880px;
padding: 30px 30px 0 30px; background: #377962; }
#content #content_left { float: left;
width: 630px; }
#content_left .product_box { float: left;
width: 200px; margin-right: 10px; }
#content_left .product_box img{ margin-bottom: 5px;
}
#content #content_right { float: right;
width: 220px; }
.right_section { width: 210px;
border: 5px solid #f8c7f2; background: #ebbce5; margin-bottom: 30px; }
.right_section_content{ width: 180px;
padding: 15px; }
.right_section_content h3{ margin-bottom: 0px; }
.right_section_content form{ padding: 0;
margin: 0; }
.right_section_content input{ width: 180px;
margin-bottom: 15px; }
.right_section_content .button{ width: 70px;
margin-bottom: 0px; }
.right_section_content ul{ list-style: none;
67
.right_section_content li { margin-bottom: 3px;
}
.right_section_content li a{ color: #be457c;
padding: 0 0 0 20px; text-decoration: none;
background: url(images/templatemo_list_icon.gif) bottom left no-repeat; }
.right_section_content li a:hover{ color: #440522;
text-decoration: none;
background: url(images/templatemo_list_icon_hover.gif) bottom left no-repeat; }
/* end of content */
/* footer */
#footer_panel{ overflow: hidden; width: 900px; padding: 15px 20px; background: #20644C; }
#footer_panel img{ margin: 0 5px 0 0; }
#footer_panel #footer_left { float: left;
width: 340px; padding: 0 25px 0 0; margin: 0 15px 0 0;
border-right: 1px solid #4c4c4c;
}
#footer_panel #footer_right { float: right;
width: 485px; text-align: left; }
/* end of footer */
Users.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Timatex Shop</title>
<link href="style.css" rel="stylesheet" type="text/css">
</head> <body>
<div id="container">
<div id="header"> <h5>Timatex Shop</h5>
<h6>Dijual Berbagai jenis kain</h6> </div>
<div id="menu_panel"> <ul>
<li><a href="index.php">Keluar</a></li>
<li><a href="admin.php" class="current">Products</a></li> <li><a href="users.php"
target="_parent" class="current">Users</a></li> <li><a href="orders.php" class="current"
target="_parent">Orders</a></li> <li><a href="about.php"></a></li> <li><a href="contact.php"></a></li> </ul>
68
<!-- end of menu --> <div id="content"> <div id="content_left">
<div class="cleaner_with_height"> </div> <h2>Daftar User</h2>
<?php
include('db.php');
$result = mysql_query("SELECT * FROM users");
echo'<table border=1">
<th>Username</th><th>Password</th><th>Role</th><td>Nama Lengkap</td> <th>Alamat</th><th>No.telp</th><th>Email</th><th>Aksi</th>';
while($row=mysql_fetch_assoc($result)) {
echo '<tr>
<td>'.$row['Username'].'</td> <td>'.$row['Password'].'</td> <td>'.$row['Role'].'</td> <td>'.$row['Realname'].'</td> <td>'.$row['Address'].'</td> <td>'.$row['Contact'].'</td> <td>'.$row['Email'].'</td>
<td><a href="deleteorder.php?ID='.$row['ID'].'">Hapus</a></td> </tr>';
}
echo '</table>';
?>
<div class="cleaner_with_height"> </div> </div>
<!-- end of ocntent left --> <div id="content_right">
<div class="templatemo_right_section"> <h4>Categories</h4>
<div class="templatemo_right_section_content"> <ul>
<?php
include('category.php'); ?>
</ul> </div> </div>
<div class="templatemo_right_section"> <h4><br>
</h4>
<div class="templatemo_right_section_content"> <br> </div>
</div> </div>
<!-- end of content right--> <div class="cleaner"> </div> </div>
<div id="footer_panel"> <div id="footer_left"> </div>
<?php
include('footer.php'); ?>
</div> </div>
<!-- Free CSS Template | Designed by TemplateMo.com --> <div align="center"><br>