Halaman Utama Tampilan Menu
Tampilan Galeri Tampilan Admin
Listing Program Halaman Utama <!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" /> <link href="css/style.css" rel="stylesheet" type="text/css" /> <title>damasus Resto</title> </head> <body> <div id="body"> <div id="banner"> <div id="menu"> include ("pages/menu_utama.php"); <div id="content"> <div id="content_kiri"> <p>selamat Datang</p> <p>website ini menyediakan informasi tentang Damasus Resto. Terutama tentang menu makanan yang tersedia pada restoran kami. Selain menu makanan, kami juga menyisipkan sebagian galeri pengunjung yang sudah menikmati hidangan yang kami sediakan.</p> <br/><p>dibawah ini adalah beberapa daftar menu makanan yang kami sediakan :</p> require_once("config/conn.php"); $tampil=mysql_query("select * FROM hidangan order by id DESC limit 0,3"); while($row=mysql_fetch_object($tampil)){ <TABLE> <TD ><img id="img-border" src=" echo("$row->photo"); " width="150"/></td> <TD valign="middle"> echo "$row->nama"; <br/> Rp. echo "$row->harga"; <br/> if ("$row->keterangan"=="") echo("keterangan tidak ada"); else echo "$row->keterangan"; <br/> <a href=" echo("$row->photo"); " target="_blank">gambar ukuran penuh... </a> </TD>
</TR> </TABLE> <hr color="#000099" size="1" width="100%" align="left"/> <p>dan dibawah ini adalah beberapa galeri pengunjung Damasus Resto :</p> require_once("config/conn.php"); $tampil=mysql_query("select * FROM galeri order by id DESC limit 0,3"); while($row=mysql_fetch_object($tampil)){ <TABLE> <TD ><img id="img-border" src=" echo("$row->photo"); " width="200"/></td> <TD valign="middle"> echo "$row->judul"; <br/> if ("$row->keterangan"=="") echo("keterangan tidak ada"); else echo "$row->keterangan"; <br/> <a href=" echo("$row->photo"); " target="_blank">gambar ukuran penuh... </a> </TD> </TR> </TABLE> <hr color="#000099" size="1" width="100%" align="left"/> <div id="content_kanan"> include("pages/buku_tamu.php"); <div id="footer"> </body> </html>
Listing Program Menu Hidangan <!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" /> <link href="css/style.css" rel="stylesheet" type="text/css" /> <title>damasus Resto</title> </head> <body> <div id="body"> <div id="banner"> <div id="menu"> include ("pages/menu_utama.php"); <div id="content"> <div id="content_kiri"> <br/><p>dibawah ini adalah beberapa daftar menu makanan yang kami sediakan :</p> require_once("config/conn.php"); $tampil=mysql_query("select * FROM hidangan order by id DESC limit 0,3"); while($row=mysql_fetch_object($tampil)){ <TABLE> <TD ><img id="img-border" src=" echo("$row->photo"); " width="150"/></td> <TD valign="middle"> echo "$row->nama"; <br/> Rp. echo "$row->harga"; <br/> if ("$row->keterangan"=="") echo("keterangan tidak ada"); else echo "$row->keterangan"; <br/> <a href=" echo("$row->photo"); " target="_blank">gambar ukuran penuh... </a> </TD> </TR> </TABLE> <hr color="#000099" size="1" width="100%" align="left"/>
<div id="content_kanan"> include("pages/buku_tamu.php"); <div id="footer"> </body> </html> Listing Program Galeri <!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" /> <link href="css/style.css" rel="stylesheet" type="text/css" /> <title>damasus Resto</title> </head> <body> <div id="body"> <div id="banner"> <div id="menu"> include ("pages/menu_utama.php"); <div id="content"> <div id="content_kiri"> <br/> Dibawah ini adalah beberapa galeri pengunjung Damasus Resto :</p> require_once("config/conn.php"); $tampil=mysql_query("select * FROM galeri order by id DESC limit 0,3"); while($row=mysql_fetch_object($tampil)){ <TABLE> <TD ><img id="img-border" src=" echo("$row->photo"); " width="200"/></td> <TD valign="middle"> echo "$row->judul"; <br/> if ("$row->keterangan"=="") echo("keterangan tidak ada"); else
echo "$row->keterangan"; <br/> <a href=" echo("$row->photo"); " target="_blank">gambar ukuran penuh... </a> </TD> </TR> </TABLE> <hr color="#000099" size="1" width="100%" align="left"/> <div id="content_kanan"> include("pages/buku_tamu.php"); <div id="footer"> </body> </html> Listing Program Pesan Pengunjung <!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" /> <link href="../css/style.css" rel="stylesheet" type="text/css" /> <title>administrator</title> </head> <body> <div id="body"> <div id="menu"> include ("menu_admin.php"); <div id="content"> <div id="content_admin"> <h3> Pesan Pengunjung</h3> $tampil=mysql_query("select * FROM buku_tamu order by id_buku_tamu DESC "); while($row=mysql_fetch_object($tampil)){
<TD >Pengirim: echo ucwords("$row->nama"); </TD> </TR> <TD ></br>mengatakan: echo "$row->pesan"; </TD> </TR> <TD align="right" width="15%"><br/><p align="right"> Dikirim pada: echo "$row->tanggal_kirim"; </p> <p align="right"> echo "<a href='hapus_pesan_pengunjung.php?id=$row- >id_buku_tamu'>hapus</font></a>"; </p></td> </TR> <TD colspan="2"> <hr color="#000099" size="1" width="100%" align="left"/> </TD> </TR> </body> </html> Listing Program Admin <style type="text/css"> <!-- body,td,th { a:link { text-decoration: none; a:visited { text-decoration: none; a:hover { text-decoration: underline; a:active { text-decoration: none; --> </style> <a href="index.php"><font color="#000000"> Beranda</font></a> <a
href="menu_hidangan.php"><font color="#000000">menu Hidangan</font></a> <a href="galeri.php"><font color="#000000">galeri</font></a> <a href="pesan_pengunjung.php"><font color="#000000">pesan Pengunjung</font></a> <a href="log-out.php"><font color="#000000">logout</font></a> edit_galeri <style> #img-border {border:#fff 2px solid; border-radius:10px </style> $id $sql $run_query $row = $_REQUEST['id']; = "SELECT * FROM galeri WHERE id='$id'"; = mysql_query($sql); = mysql_fetch_array($run_query); <br/> <hr color="#000099" size="1" width="100%" align="left"/> <form name="edit" method="post" enctype="multipart/form-data" action="proses_edit_galeri.php"> <table width="700" height="112" align="center"> <tr> <td width="202" height="24" >Judul</td> <td width="448"><input type="hidden" value=" echo $row['id']; " name="id"/><input name="judul" type="text" id="judul" value=" echo $row['judul']; " size="70" /></td> <tr> <td height="24" >Photo</td> <td valign="top"><p><img id="img-border" src="../ echo $row['photo']; " width="300"/></p> <p>*) File gambar tidak bisa di ubah.</p> <p> </p></td> <tr> <td height="24" >Keterangan</td> <td><textarea name="keterangan" cols="85" rows="3" id="keterangan"></textarea></td> <br/>
<td height="28" colspan="2"><div align="right"> <input type="submit" name="submit" value="tambah"> </td> </table> </form> <hr color="#000099" size="1" width="100%" align="left"/> edit_menu_hidangan <style> #img-border {border:#fff 2px solid; border-radius:10px </style> $id $sql $run_query $row = $_REQUEST['id']; = "SELECT * FROM hidangan WHERE id='$id'"; = mysql_query($sql); = mysql_fetch_array($run_query); <br/> <hr color="#000099" size="1" width="100%" align="left"/> <form name="edit" method="post" enctype="multipart/form-data" action="proses_edit_menu_hidangan.php"> <table width="700" height="164" align="center"> <tr> <td width="202" height="24" >Nama</td> <td width="448"><input type="hidden" value=" echo $row['id']; " name="id"/><input name="nama" type="text" id="nama" value=" echo $row['nama']; " size="70" /></td> <tr> <td height="24" >Harga</td> <td><input name="harga" type="text" id="harga" value=" echo $row['harga']; " size="10" /> Rupiah</td> <tr> <td height="24" >Photo</td> <td valign="top"><p><img id="img-border" src="../ echo $row['photo']; " width="300"/></p> <p>*) File gambar tidak bisa di ubah.</p> <p> </p></td> <tr> <td height="24" >Keterangan</td>
<td><textarea name="keterangan" cols="85" rows="3" id="keterangan"></textarea></td> <br/> <td height="28" colspan="2"><div align="right"> <input type="submit" name="submit" value="tambah"> </td> </table> </form> <hr color="#000099" size="1" width="100%" align="left"/> hapus_galeri $id=$_request[id]; $sql = "DELETE FROM galeri WHERE id=$id"; $hasil = mysql_query($sql); header("location:galeri.php"); hapus_ menu_hidangan $id=$_request[id]; $sql = "DELETE FROM hidangan WHERE id=$id"; $hasil = mysql_query($sql); header("location:menu_hidangan.php"); hapus_pesan_pengunjung $id=$_request[id];
$sql = "DELETE FROM buku_tamu WHERE id_buku_tamu=$id"; $hasil = mysql_query($sql); header("location:pesan_pengunjung.php"); log-out session_start(); $nama = $_SESSION['nama']; session_unset(); header("location:../index.php"); proses_edit_galeri $id = $_REQUEST['id']; $judul = $_REQUEST['judul']; $keterangan = $_REQUEST['keterangan']; $sql = "UPDATE galeri SET judul='$judul', keterangan='$keterangan' where id='$id'"; $run_query = mysql_query($sql); header("location:galeri.php"); proses_edit_menu_hidangan $id = $_REQUEST['id']; $nama = $_REQUEST['nama']; $harga = $_REQUEST['harga']; $keterangan = $_REQUEST['keterangan']; $sql = "UPDATE hidangan SET nama='$nama',harga='$harga', keterangan='$keterangan' where id='$id'"; $run_query = mysql_query($sql);
header("location:menu_hidangan.php"); proses_tambah_galeri require_once('../config/conn.php'); $judul=$_post['judul']; $photo_galeri=$_files['photo']; $keterangan=$_post["keterangan"]; $nama=$photo_galeri["name"]; if(copy($photo_galeri["tmp_name"],"../images/galeri/$nama")) { $photo_galeri="images/galeri/".$nama; $simpan="insert into galeri values('', '$judul','$photo_galeri','$keterangan')"; mysql_query($simpan); header("location:galeri.php"); proses_tambah_menu_hidangan require_once('../config/conn.php'); $nama_hidangan=$_post['nama']; $harga=$_post['harga']; $photo_hidangan=$_files['photo']; $keterangan=$_post["keterangan"]; $nama=$photo_hidangan["name"]; if(copy($photo_hidangan["tmp_name"],"../images/hidangan/$nama") ) { $photo_hidangan="images/hidangan/".$nama; $simpan="insert into hidangan values('', '$nama_hidangan','$harga','$photo_hidangan','$keteran gan')"; mysql_query($simpan); header("location:menu_hidangan.php");
Connection mysql_connect("localhost","root",""); mysql_select_db("damasus");