Gambar 4. 2 Halaman Utama Admin.
c. Halaman Hapus Wisata
Tampilan berikut ini adalah tampilan hapus data hotel yang dilihat oleh admin. Pada halaman ini admin dapat
melakukan proses hapus data wisata.
Gambar 4. 3 Halaman Hapus Data Wisata.
Listing untuk menampilkan data dan menghapus data pada tabel data wisata
1. div class=col-md-12
2. h1Tabel Data Wisatah1
3. div
4. div
5. div class=row
6. div class=col-md-12
7. table class=table border=1
8. thead
9. tr
10. thId Wisatath 11. thNama Tempat wisatath
12. thAlamatth 13. thHargath
14. thTlp Pengelolath 15. thKeteranganth
16. thLongtitudeth 17. thLatitudeth
18. tr 19. ?php
20. include ..KoneksiConeksi.php; 21. query = mysql_queryselect from Wisata;
22. while row = mysql_fetch_arrayquery { 23. echo tr;
24. echo thspan . row[Id_wisata] . th; 25. echo thspan . row[Nama_wisata] . th;
26. echo thspan . row[Alamat] . th; 27. echo thspan . row[Harga] . th;
28. echo thspan . row[No_tlp] . th; 29. echo thspan . row[Keterangan] . th;
30. echo thspan . row[Longtitude] . th; 31. echo thspan . row[Latitude] . th;
32. echo
tddiv align=centera
href=Hapuswisata.php?Idwisata= . row[Id_wisata] . class=delbutton title=Click To Deletedeleteadivtd;
33. echo tr; 1.
if_GET[Idwisata]{ 2.
idwisata =_GET[Idwisata]; 3.
4. sql=Delete from wisata
5. Where Id_wisata=idwisata;
6. hasil= mysql_querysql;
7. if hasil{
8. echo
script language=javascriptalertData
Berhsil Dihapusscript;
9. echo
script language=javascriptwindow.location
= Lihat_datawisata.php script;
10. 11. } else {
12. echo script
language=javascriptalertData Gagal
Dihapusscript; 13. echo
script language=javascriptwindow.location
= Hapus_datawisata.php script;
14. } 15. }
d. Halaman Hapus Hotel