Sistem Informasi Manajemen Pendaftaran Balap Sepeda Berbasis Web.

80  Download (0)

Full text

(1)

Universitas Kristen Maranatha

Jalan Prof. drg. Surya Sumantri MPH 65

Bandung

ABSTRAK

(2)

Jalan Prof. drg. Surya Sumantri MPH 65

Bandung

ABSTRACT

(3)

Abstract

ii

Kata Pengantar

iii

Daftar Isi

iv

Daftar Gambar

vii

Daftar Tabel

ix

BAB I PENDAHULUAN

1.1 Latar Belakang

1

1.2 Identifikasi Masalah

2

1.3 Ruanglingkup Permasalahan

3

1.4 Tujuan Perancangan

3

1.5 Sistematika Penulisan

4

BAB II LANDASAN TEORI

2.1 Teori tentang permasalahan

6

2.1.1 Sekilas Aplikasi

Web

6

2.1.2 Pengertian Balap

7

2.1.3 Pengertian Sepeda

7

2.1.4 Sekilas tentang

Web

8

2.1.5 Sekilas Pengertian PHP

9

2.1.6 Pengertian MYSQL

10

2.1.7 Konsep Dasar Informasi

13

2.1.8 Konsep Dasar Sistem Informasi

13

2.1.9 Konsep Dasar Database

14

(4)

BAB III PERANCANGAN

1.1 Gambaran Perangkat Lunak

21

1.1.1 Uraian Tekstual

21

1.1.2

FlowChart

Sistem

23

1.2 Analisis Fungsional

27

1.3 Analisis Data

30

1.3.1 Skema Relasi

30

1.3.2 Perancangan

Database

30

1.3.3 Data

Dictionary

32

1.3.3.1 Data

Dictionary Team

32

1.3.3.2 Data

Dictionary

Negara

32

1.3.3.3 Data

Dictionary

Peserta

33

1.3.3.4 Data

Dictionary Head

Regis

33

1.3.3.5 Data

Dictionary

Jenis Lomba

33

1.3.3.6 Data

Dictionary

Klasifikasi

34

1.3.4 Tabel dalam Database

34

BAB IV IMPLEMENTASI DAN PENGUJIAN

4.1 Implementasi

39

4.2 Kebutuhan Sumberdaya

43

4.3 Pengujian

43

4.3.1 Menu

44

4.3.2 Format Dokumen/Formulir

Output

45

(5)

Daftar Pustaka

65

(6)

Gambar 2.2 Aliran Data

18

Gambar 2.3 Proses

19

Gambar 2.4

Data Store

19

Gambar 3.1 Sistem Pendaftaran Balap Sepeda(Sistem Berjalan)

23

Gambar 3.2 Sistem Pendaftaran Balap Sepeda Lanjutan(Sistem Berjalan)

24

Gambar 3.3 Sistem Pendaftaran Balap Sepeda(Sistem Baru)

25

Gambar 3.4 Sistem Pendaftaran Balap Sepeda Lanjutan(Sistem Baru)

26

Gambar 3.5 Conteks Diagram Pendaftaran Balap Sepeda(Sistem Baru)

28

Gambar 3.6

DFD

Level 1 Pendaftaran Balap Sepeda

29

Gambar 3.7

Relational Database

(Sistem Baru)

31

Gambar 4.1 Menu Admin

44

Gambar 4.2 Menu

User

44

Gambar 4.3 Bukti Regis

45

Gambar 4.4 Laporan Peserta

46

Gambar 4.5

Layout

Peserta

46

Gambar 4.6

Layout

Pendaftaran

47

Gambar 4.7

Layout

Pilihan Jenis Lomba

48

Gambar 4.8

Layout

Jumlah Jenis Lomba

48

Gambar 4.9

Layout

Peserta Regis

49

Gambar 4.10

Layout

Jenis Lomba yang diikuti

50

Gambar 4.11

Layout

Daftar Juara

50

Gambar 4.12

Layout

Cetak Bukti Regis

51

(7)

Gambar 4.17 Pesan

Box

Data Jenis Lomba telah diubah

54

Gambar 4.18

Layout

Pesan

Box

Data Jenis Lomba Telah Dihapus

54

Gambar 4.19

Layout

Klasifikasi

55

Gambar 4.20

Layout

Input

Klasifikasi

55

Gambar 4.21

Layout

Pesan

Box

Data Klasifikasi telah disimpan

56

Gambar 4.22

Layout

Ubah Klasifikasi

56

Gambar 4.23

Layout

Pesan

Box

Data Klasifikasi Telah Diubah

57

Gambar 4.24

Layout

Pesan

Box

Data Klasifikasi Telah Dihapus

57

Gambar 4.25

Layout

Negara

58

Gambar 4.26

Layout

Input

Negara

58

Gambar 4.27

Layout

Pesan

Box

Data Negara Telah Disimpan

59

Gambar 4.28

Layout

Ubah Negara

59

Gambar 4.29

Layout

Pesan

Box

Data Negara Telah Diubah

59

Gambar 4.30

Layout

Pesan

Box

Data Negara Telah Dihapus

60

Gambar 4.31

Layout

Peserta

60

Gambar 4.32

Layout

Lihat Peserta

61

Gambar 4.33

Layout

Lihat Skor

62

Gambar 4.34

Layout

Pesan

Box

Data Peserta Telah Dihapus

62

Gambar 4.35

Layout

Team

63

(8)

Tabel 3.3 Tabel Peserta

36

Tabel 3.4 Tabel Jenis Lomba

37

Tabel 3.5 Tabel

Head

Regis

37

Tabel 3.6 Tabel Det Regis

38

Tabel 3.7 Tabel Negara

38

(9)

A-1

Universitas Kristen Maranatha <html>

<head>

<title>lomba Sepeda</title> </head>

<body> <?php

function formatrp($angka){

$rupiah=number_format($angka,2,',','.'); return $rupiah;

} ?>

<table bgcolor="black"border="1" width="100%" height="150" align="center"> <tr>

<td align="center"> <a href ="index.php?menu=home"> <h2><font color="widh">Lomba Sepeda</h2></a> </td>

</tr> </table>

<center>

<table border="0" align="center"> <tr>

<td>

<h2> <a href="?menu=jenis_lomba">Jenis Lomba</a> | <a

(10)

href="?menu=negara">Negara</a> | <a href="?menu=peserta">Peserta</a> | <a href="?menu=team">Team</a></h2> </td>

</tr> </table> </center>

<br></br><br></br> <?php

switch($_GET['menu']){ default; case"home";

echo"<h2>Hello Admin</h2> "; break;

case"jenis_lomba";

include"pages/jenis_lomba/view.php"; break;

case"addjenis";

include"pages/jenis_lomba/add.php"; break;

case"editjenis";

include"pages/jenis_lomba/edit.php"; break;

case"deljenis";

(11)

break;

case"negara";

include"pages/negara/view.php"; break;

case"addnegara";

include"pages/negara/add.php"; break;

case"editnegara";

include"pages/negara/edit.php"; break;

case"delnegara";

include"pages/negara/del.php"; break;

case"klasifikasi";

include"pages/klasifikasi/view.php"; break;

case"addklasifikasi";

include"pages/klasifikasi/add.php"; break;

case"editklasifikasi";

(12)

break;

case"delklasifikasi";

include"pages/klasifikasi/del.php"; break;

case"team";

include"pages/team/view.php"; break;

case"addteam";

include"pages/team/add.php"; break;

case"editteam";

include"pages/team/edit.php"; break;

case"delteam";

include"pages/team/del.php"; break;

case"skor";

include"pages/peserta/skor.php"; break;

case"peserta";

(13)

break;

case"delpeserta";

include"pages/peserta/del.php"; break;

case"detpeserta";

include"pages/peserta/view_detail.php"; break;

case"laporan_peserta";

include"pages/peserta/cetak.php"; break;

case"cari_peserta";

include"pages/peserta/cari_peserta.php"; break;

case"print_all";

include"pages/peserta/print_all.php"; break;

} ?>

<br></br><br></br> </body>

</html>

(14)

include("../connect/connect.php"); if(isset($_POST['simpan'])) {

$uploaddir = getcwd().'/../gambar_lomba/';

$uploadfile = str_replace(" ","_",$uploaddir.date("dmyhmst").$_FILES['gambar']['name']); if (move_uploaded_file($_FILES['gambar']['tmp_name'], $uploadfile))

{

$gambar = str_replace(" ","_",date("dmyhmst").$_FILES['gambar']['name']); $q=mysql_query("INSERT INTO `jenis_lomba` (`kode_jenis`, `tahun_seri`, `nama`, `tgl`, `kota`, `propinsi`, `biaya`, `keterangan`, `gambar`) VALUES (NULL, '".$_POST['tahun_seri']."', '".$_POST['nama']."', '".$_POST['tgl']."', '".$_POST['kota']."', '".$_POST['propinsi']."', '".$_POST['biaya']."',

'".$_POST['keterangan']."', '$gambar')");

echo "<script>alert(\"data berhasil dimasukan!\")</script>"; echo"<script>location.href='?menu=jenis_lomba'</script>"; }

} ?>

<h2>Tambah Jenis Lomba</h2> <br><br><br><br>

<form method="POST" > <table border="0">

<tr>

<td>Tahun Seri &nbsp;</td>

<td><input type="text" name="tahun_seri" size="10" /></td> </tr>

<tr>

<td>Nama</td>

(15)

</tr> <tr>

<td>Tanggal</td>

<td><input type="text" name="tgl" size="30" /></td> </tr>

<tr>

<td>Kota</td>

<td><input type="text" name="kota" size="30" /></td> </tr>

<tr>

<td>Propinsi</td>

<td><input type="text" name="propinsi" size="30" /></td> </tr>

<tr>

<td>Biaya</td>

<td><input type="text" name="biaya" size="30" /></td> </tr>

<tr>

<td>Keterangan</td>

<td><input type="text" name="keterangan" size="30" /></td> </tr>

<tr>

<td>Gambar</td>

<td><input type="file" name="gambar" /></td> </tr>

<tr>

(16)

<td><input type="submit" value="simpan" name="simpan" /></td> </tr>

</table> </form>

Program Del Jenis Lomba <?php

include("../connect/connect.php");

mysql_query("DELETE FROM `jenis_lomba` WHERE kode_jenis='".$_GET['id']."'"); echo "<script>alert(\"data berhasil dihapus!\")</script>";

echo"<script>location.href='?menu=jenis_lomba'</script>"; ?>

Program Edit Jenis Lomba <?PHP

include("../connect/connect.php");

$query= mysql_query("select * FROM jenis_lomba WHERE kode_jenis='$_GET[id]'");

$num = mysql_num_rows($query); for ($i=0;$i<$num;$i++) {

$f = mysql_fetch_array($query); }

?>

<h2>Ubah Jenis Lomba</h2> <br><br><br><br>

<form method="POST" > <table border="0">

<tr>

<td>Tahun Seri &nbsp;</td>

(17)

</tr> <tr>

<td>Nama</td>

<td><input type="text" name="nama" size="40" value="<?php echo $f['nama']; ?>" /></td>

</tr> <tr>

<td>Tanggal</td>

<td><input type="text" name="tgl" size="30" id="inputField" value="<?php echo $f['tgl']; ?>" /></td>

</tr> <tr>

<td>Kota</td>

<td><input type="text" name="kota" size="30" value="<?php echo $f['kota']; ?>" /></td>

</tr> <tr>

<td>Propinsi</td>

<td><input type="text" name="propinsi" size="30" value="<?php echo $f['propinsi']; ?>" /></td>

</tr> <tr>

<td>Biaya</td>

<td><input type="text" name="biaya" size="30" value="<?php echo $f['biaya']; ?>" /></td>

</tr> <tr>

<td>Keterangan</td>

(18)

</tr> <tr>

<td>&nbsp;</td>

<td><input type="submit" value="Ubah" name="Ubah" /></td> </tr>

</table> </form> <?php

if (isset($_POST['Ubah'])) { include("../connect/connect.php");

$q = mysql_query("UPDATE jenis_lomba SET tahun_seri='".$_POST['tahun_seri']."', nama='".$_POST['nama']."', tgl='".$_POST['tgl']."', kota='".$_POST['kota']."',

propinsi='".$_POST['propinsi']."', biaya='".$_POST['biaya']."',

keterangan='".$_POST['keterangan']."' where kode_jenis='$_GET[id]'"); echo "<script>alert(\"data berhasil diubah!\")</script>";

echo"<script>location.href='?menu=jenis_lomba'</script>"; }

?>

Program View Jenis Lomba <h2>Jenis Lomba</h2>

<p align="right"><a href="<?php echo"?menu=addjenis"; ?>">add New</a></p> <table border="0" width="100%">

<tr bgcolor="#2b2e2e">

(19)

<td align="center"><font color="#FFFFFF"><b>Biaya</b></font></td> <td align="center"><font color="#FFFFFF"><b>Keterangan</b></font></td> <td align="center"><font color="#FFFFFF"><b>Gambar</b></font></td> <td>&nbsp;</td>

<td>&nbsp;</td> </tr>

<tr> <?PHP

include("../connect/connect.php");

$query= mysql_query("select * FROM jenis_lomba order by kode_jenis desc"); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); $id = $row['kode_jenis'];

$number = $row['biaya']; $rp = formatrp($number); ?>

<td bgcolor="#f4909e"><?php echo $row['kode_jenis'] ?></td> <td bgcolor="#f4909e"><?php echo $row['tahun_seri'] ?></td> <td bgcolor="#f4909e"><?php echo $row['nama'] ?></td> <td bgcolor="#f4909e"><?php echo $row['tgl'] ?></td> <td bgcolor="#f4909e"><?php echo $row['kota'] ?></td> <td bgcolor="#f4909e"><?php echo $row['propinsi'] ?></td> <td bgcolor="#f4909e"><?php echo "Rp. $rp"; ?></td>

(20)

<td bgcolor="#f4909e"><?php echo '<a

href="?menu=editjenis&id='.$id.'">Edit</a>'; ?></td> <td bgcolor="#f4909e"><?php echo '<a

href="?menu=deljenis&id='.$id.'">Del</a>'; ?></td> </tr>

<?php }} ?> </table>

Program add Klasifikasi <?php

include("../connect/connect.php"); if(isset($_POST['simpan'])) {

$q=mysql_query("INSERT INTO `klasifikasi` (`kode_klasifikasi`, `klasifikasi`, `min_umur`, `max_umur`) VALUES (NULL, '".$_POST['klasifikasi']."',

'".$_POST['min_umur']."', '".$_POST['max_umur']."')"); echo "<script>alert(\"data berhasil dimasukan!\")</script>"; echo"<script>location.href='?menu=klasifikasi'</script>"; }

?>

<h2>Tambah Klasifikasi</h2> <br><br><br><br>

<form method="POST" > <table border="0">

<tr>

<td>Klasifikasi &nbsp;</td>

(21)

<tr>

<td>Min Umur &nbsp;</td>

<td><input type="text" name="min_umur" size="20" /></td> </tr>

<tr>

<td>Max Umur &nbsp;</td>

<td><input type="text" name="max_umur" size="20" /></td> </tr>

<tr>

<td>&nbsp;</td>

<td><input type="submit" value="simpan" name="simpan" /></td> </tr>

</table> </form>

Program Del Klasifikasi <?php

include("../connect/connect.php");

mysql_query("DELETE FROM `klasifikasi` WHERE kode_klasifikasi='".$_GET['id']."'"); echo "<script>alert(\"data berhasil dihapus!\")</script>";

echo"<script>location.href='?menu=klasifikasi'</script>"; ?>

Program Edit Klasifikasi <?PHP

include("../connect/connect.php");

$query= mysql_query("select * FROM klasifikasi WHERE kode_klasifikasi='$_GET[id]'");

$num = mysql_num_rows($query); for ($i=0;$i<$num;$i++) {

(22)

} ?>

<h2>Ubah Klasifikasi</h2> <br><br><br><br>

<form method="POST" > <table border="0">

<tr>

<td>Klasifikasi &nbsp;</td>

<td><input type="text" name="klasifikasi" size="40" value="<?php echo $f['klasifikasi']; ?>" /></td>

</tr> <tr>

<td>Min Umur &nbsp;</td>

<td><input type="text" name="min_umur" size="20" value="<?php echo $f['min_umur']; ?>" /></td>

</tr> <tr>

<td>Max Umur &nbsp;</td>

<td><input type="text" name="max_umur" size="20" value="<?php echo $f['max_umur']; ?>" /></td>

</tr> <tr>

<td>&nbsp;</td>

<td><input type="submit" value="Ubah" name="Ubah" /></td> </tr>

</table> </form> <?php

(23)

include("../connect/connect.php");

$q = mysql_query("UPDATE klasifikasi SET klasifikasi='".$_POST['klasifikasi']."', min_umur='".$_POST['min_umur']."', max_umur='".$_POST['max_umur']."' where kode_klasifikasi='$_GET[id]'");

echo "<script>alert(\"data berhasil diubah!\")</script>"; echo"<script>location.href='?menu=klasifikasi'</script>"; }

?>

Program View Klasifikasi <h2>Klasifikasi</h2>

<p align="right"><a href="<?php echo"?menu=addklasifikasi"; ?>">add New</a></p> <table border="0" width="100%">

<tr bgcolor="#2b2e2e">

<td align="center"><font color="#FFFFFF"><b>Kode Klasifikasi</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Klasifikasi</b></font></td> <td align="center"><font color="#FFFFFF"><b>Min Umur</b></font></td> <td align="center"><font color="#FFFFFF"><b>Max Umur</b></font></td> <td>&nbsp;</td>

<td>&nbsp;</td> </tr>

<tr> <?PHP

include("../connect/connect.php");

$query= mysql_query("select * FROM klasifikasi order by kode_klasifikasi desc"); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

(24)

$id = $row['kode_klasifikasi']; ?>

<td bgcolor="#f4909e"><?php echo $row['kode_klasifikasi'] ?></td> <td bgcolor="#f4909e"><?php echo $row['klasifikasi'] ?></td> <td bgcolor="#f4909e"><?php echo $row['min_umur'] ?></td> <td bgcolor="#f4909e"><?php echo $row['max_umur'] ?></td> <td bgcolor="#f4909e"><?php echo '<a

href="?menu=editklasifikasi&id='.$id.'">Edit</a>'; ?></td> <td bgcolor="#f4909e"><?php echo '<a

href="?menu=delklasifikasi&id='.$id.'">Del</a>'; ?></td> </tr>

<?php }} ?> </table>

Program Add Negara <?php

include("../connect/connect.php"); if(isset($_POST['simpan'])) {

$q=mysql_query("INSERT INTO `negara` (`kode_negara`, `nama_negara`) VALUES (NULL, '".$_POST['nama']."')");

echo "<script>alert(\"data berhasil dimasukan!\")</script>"; echo"<script>location.href='?menu=negara'</script>"; }

?>

<h2>Tambah Negara</h2> <br><br><br><br>

(25)

<table border="0"> <tr>

<td>Nama Negara &nbsp;</td>

<td><input type="text" name="nama" size="40" /></td> </tr>

<tr>

<td>&nbsp;</td>

<td><input type="submit" value="simpan" name="simpan" /></td> </tr>

</table> </form>

Program Del Negara <?php

include("../connect/connect.php");

mysql_query("DELETE FROM `negara` WHERE kode_negara='".$_GET['id']."'"); echo "<script>alert(\"data berhasil dihapus!\")</script>";

echo"<script>location.href='?menu=negara'</script>"; ?>

Program Edit Negara <?PHP

include("../connect/connect.php");

$query= mysql_query("select * FROM negara WHERE kode_negara='$_GET[id]'"); $num = mysql_num_rows($query);

for ($i=0;$i<$num;$i++) {

$f = mysql_fetch_array($query); }

?>

(26)

<br><br><br><br> <form method="POST" > <table border="0">

<tr>

<td>Nama Negara &nbsp;</td>

<td><input type="text" name="nama" size="40" value="<?php echo $f['nama_negara']; ?>" /></td>

</tr> <tr>

<td>&nbsp;</td>

<td><input type="submit" value="Ubah" name="Ubah" /></td> </tr>

</table> </form> <?php

if (isset($_POST['Ubah'])) { include("../connect/connect.php");

$q = mysql_query("UPDATE negara SET nama_negara='".$_POST['nama']."' where kode_negara='$_GET[id]'");

echo "<script>alert(\"data berhasil diubah!\")</script>"; echo"<script>location.href='?menu=negara'</script>"; }

?>

Program View Negara <h2>Negara</h2>

<p align="right"><a href="<?php echo"?menu=addnegara"; ?>">add New</a></p> <table border="0" width="100%">

(27)

<td align="center"><font color="#FFFFFF"><b>Kode Negara</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Nama</b></font></td> <td>&nbsp;</td>

<td>&nbsp;</td> </tr>

<tr> <?PHP

include("../connect/connect.php");

$query= mysql_query("select * FROM negara order by kode_negara desc"); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); $id = $row['kode_negara'];

?>

<td bgcolor="#f4909e"><?php echo $row['kode_negara'] ?></td> <td bgcolor="#f4909e"><?php echo $row['nama_negara'] ?></td> <td bgcolor="#f4909e"><?php echo '<a

href="?menu=editnegara&id='.$id.'">Edit</a>'; ?></td> <td bgcolor="#f4909e"><?php echo '<a

href="?menu=delnegara&id='.$id.'">Del</a>'; ?></td> </tr>

<?php }} ?> </table>

(28)

include("../connect/connect.php");

mysql_query("DELETE FROM `peserta` WHERE id_peserta='".$_GET['id']."'"); echo "<script>alert(\"data berhasil dihapus!\")</script>";

echo"<script>location.href='?menu=peserta'</script>"; ?>

Program Print all Peserta <script type="text/javascript"> function printpage()

{

window.print() }

</script>

<h2>Peserta</h2>

<table border="0" width="100%"> <tr bgcolor="#2b2e2e">

<td align="center"><font color="#FFFFFF"><b>ID Peserta</b></font></td> <td align="center"><font color="#FFFFFF"><b>Nama</b></font></td> <td align="center"><font color="#FFFFFF"><b>JK</b></font></td>

<td align="center"><font color="#FFFFFF"><b>No Rek</b></font></td> <td align="center"><font color="#FFFFFF"><b>Email</b></font></td> <td align="center"><font color="#FFFFFF"><b>Negara</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Team</b></font></td> <td align="center"><font color="#FFFFFF"><b>Status</b></font></td>

(29)

include("../connect/connect.php");

$query= mysql_query("select * from peserta"); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); $id = $row['id_peserta'];

?>

<td bgcolor="#f4909e"><?php echo $row['id_peserta'] ?></td> <td bgcolor="#f4909e"><?php echo $row['nama'] ?></td>

<td bgcolor="#f4909e"><?php echo $row['jenis_kelamin'] ?></td> <td bgcolor="#f4909e"><?php echo $row['no_rekening'] ?></td> <td bgcolor="#f4909e"><?php echo $row['email'] ?></td>

<td bgcolor="#f4909e"><?php echo $row['kode_negara'] ?></td> <td bgcolor="#f4909e"><?php echo $row['kode_team'] ?></td> <td bgcolor="#f4909e"><?php echo $row['status'] ?></td>

</tr> <?php }} ?> </table>

<p align="right"><input type="button" value="Print" onclick="printpage()" /></p> Program Print Periode Peserta

<script type="text/javascript"> function printpage()

{

(30)

} </script> <?PHP

include("../../../connect/connect.php");

$query= mysql_query("select head_regis.tgl, head_regis.no_regis, peserta.umur, klasifikasi.klasifikasi, peserta.password, peserta.foto, peserta.id_peserta, head_regis.tgl, peserta.nama, peserta.jenis_kelamin, peserta.no_rekening, peserta.email,

negara.nama_negara, team.nama_team FROM peserta, head_regis, negara, team, klasifikasi WHERE peserta.id_peserta=head_regis.id_peserta and

peserta.kode_negara=negara.kode_negara and peserta.kode_team=team.kode_team and head_regis.kode_klasifikasi=klasifikasi.kode_klasifikasi and head_regis.tgl >=

'".$_GET['dari_tanggal']."' AND head_regis.tgl <= '".$_GET['sampai_tanggal']."' order by peserta.id_peserta desc");

$num = mysql_num_rows($query); if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); $id = $row['id_peserta'];

$noreg = $row['no_regis']; ?>

<table border="0"> <tr>

<td>Password</td> <td>:</td>

<td><?php echo $row['password']; ?></td> </tr>

<tr>

<td>Nama</td> <td>:</td>

(31)

<tr>

<td>Jenis Kelamin</td> <td>:</td>

<td><?php echo $row['jenis_kelamin']; ?></td> </tr>

<tr>

<td>Team</td> <td>:</td>

<td><?php echo $row['nama_team']; ?></td> </tr>

<tr>

<td>Umur</td> <td>:</td>

<td><?php echo $row['umur']; ?></td> </tr>

<tr>

<td>Klasifikasi</td> <td>:</td>

<td><?php echo $row['klasifikasi']; ?></td> </tr>

</table>

<table border="0">

<tr bgcolor="#2b2e2e">

<td align="center"><font color="#FFFFFF"><b>Kode Jenis</b></font></td> <td align="center"><font color="#FFFFFF"><b>Tahun Seri</b></font></td>

(32)

<td align="center"><font color="#FFFFFF"><b>Kota</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Provinsi</b></font></td> <td align="center"><font color="#FFFFFF"><b>Biaya</b></font></td> </tr>

<?PHP

$query_jenis= mysql_query("select detail_regis.no_regis, jenis_lomba.kode_jenis, jenis_lomba.tahun_seri, jenis_lomba.nama, jenis_lomba.tgl, jenis_lomba.kota, jenis_lomba.propinsi, jenis_lomba.biaya FROM jenis_lomba, detail_regis where jenis_lomba.kode_jenis=detail_regis.kode_jenis and no_regis='".$noreg."' order by kode_jenis desc");

$num_jenis = mysql_num_rows($query_jenis); if ($num_jenis > 0){

for ($i=0; $i < $num_jenis; $i++){

$rowe = mysql_fetch_array($query_jenis); ?>

<tr>

<td align="center"><?php echo $rowe['kode_jenis']; ?></td> <td align="center"><?php echo $rowe['tahun_seri']; ?></td> <td align="center"><?php echo $rowe['nama']; ?></td> <td align="center"><?php echo $rowe['tgl']; ?></td> <td align="center"><?php echo $rowe['kota']; ?></td> <td align="center"><?php echo $rowe['propinsi']; ?></td> <td align="center"><?php echo $rowe['biaya']; ?></td> </tr>

(33)

}} ?>

<p align="right"><input type="button" value="Print" onclick="printpage()" /></p> Program Skor Peserta

<?php

include("../connect/connect.php"); if(isset($_POST['simpan'])) {

if($_POST['skor']=="") {

echo "<script>alert(\"tidak boleh kosong!\")</script>"; }else{

$q= mysql_query("update detail_regis set waktu='".$_POST['waktu']."', skor='".$_POST['skor']."' where no_regis='".$_GET['id']."'");

echo"<script>location.href='?menu=detpeserta&id=$GET[id]'</script>"; }

} ?>

<form method="POST" > <table border="0">

<tr>

<td>Waktu &nbsp;</td> <td>:</td>

<td><input type="text" name="waktu" /></td> </tr>

<tr>

(34)

<td>:</td>

<td><input type="text" name="skor" /></td> </tr>

<tr>

<td>&nbsp;</td> <td>&nbsp;</td>

<td><input type="submit" name="simpan" value="save" /></td> </tr>

</table> </form>

Program View Peserta <h2>Peserta</h2> <br/><br/>

<table border="0" width="100%"> <tr bgcolor="#2b2e2e">

<td align="center"><font color="#FFFFFF"><b>ID Peserta</b></font></td> <td align="center"><font color="#FFFFFF"><b>Nama</b></font></td> <td align="center"><font color="#FFFFFF"><b>JK</b></font></td>

<td align="center"><font color="#FFFFFF"><b>No Rek</b></font></td> <td align="center"><font color="#FFFFFF"><b>Email</b></font></td> <td align="center"><font color="#FFFFFF"><b>Negara</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Team</b></font></td> <td align="center"><font color="#FFFFFF"><b>Tgl</b></font></td> <td>&nbsp;</td>

<td>&nbsp;</td> </tr>

(35)

<?PHP

include("../connect/connect.php");

$query= mysql_query("select peserta.foto, peserta.id_peserta, head_regis.tgl, peserta.nama, peserta.jenis_kelamin, peserta.no_rekening, peserta.email,

negara.nama_negara, team.nama_team FROM peserta, head_regis, negara, team WHERE peserta.id_peserta=head_regis.id_peserta and

peserta.kode_negara=negara.kode_negara and

peserta.kode_team=team.kode_team order by peserta.id_peserta desc "); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); $id = $row['id_peserta'];

?>

<td bgcolor="#f4909e"><?php echo $row['id_peserta'] ?></td> <td bgcolor="#f4909e"><?php echo $row['nama'] ?></td>

<td bgcolor="#f4909e"><?php echo $row['jenis_kelamin'] ?></td> <td bgcolor="#f4909e"><?php echo $row['no_rekening'] ?></td> <td bgcolor="#f4909e"><?php echo $row['email'] ?></td>

<td bgcolor="#f4909e"><?php echo $row['nama_negara'] ?></td> <td bgcolor="#f4909e"><?php echo $row['nama_team'] ?></td> <td bgcolor="#f4909e"><?php echo $row['tgl'] ?></td>

<td bgcolor="#f4909e"><?php echo '<a

href="?menu=detpeserta&id='.$id.'">Det</a>'; ?></td> <td bgcolor="#f4909e"><?php echo '<a

href="?menu=delpeserta&id='.$id.'">Del</a>'; ?></td> </tr>

(36)

<br>

<a href="?menu=print_all">Laporan</a> Program View_detail Peserta

<h2>Peserta</h2> <br/><br/>

<table border="0" width="100%"> <tr bgcolor="#2b2e2e">

<td align="center"><font color="#FFFFFF"><b>ID Peserta</b></font></td> <td align="center"><font color="#FFFFFF"><b>Nama</b></font></td> <td align="center"><font color="#FFFFFF"><b>JK</b></font></td>

<td align="center"><font color="#FFFFFF"><b>No Rek</b></font></td> <td align="center"><font color="#FFFFFF"><b>Email</b></font></td> <td align="center"><font color="#FFFFFF"><b>Negara</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Team</b></font></td> <td align="center"><font color="#FFFFFF"><b>Tgl</b></font></td> <td>&nbsp;</td>

<td>&nbsp;</td> </tr>

<tr> <?PHP

include("../connect/connect.php");

$query= mysql_query("select peserta.foto, peserta.id_peserta, head_regis.tgl, peserta.nama, peserta.jenis_kelamin, peserta.no_rekening, peserta.email,

negara.nama_negara, team.nama_team FROM peserta, head_regis, negara, team WHERE peserta.id_peserta=head_regis.id_peserta and

peserta.kode_negara=negara.kode_negara and

peserta.kode_team=team.kode_team order by peserta.id_peserta desc "); $num = mysql_num_rows($query);

(37)

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); $id = $row['id_peserta'];

?>

<td bgcolor="#f4909e"><?php echo $row['id_peserta'] ?></td> <td bgcolor="#f4909e"><?php echo $row['nama'] ?></td>

<td bgcolor="#f4909e"><?php echo $row['jenis_kelamin'] ?></td> <td bgcolor="#f4909e"><?php echo $row['no_rekening'] ?></td> <td bgcolor="#f4909e"><?php echo $row['email'] ?></td>

<td bgcolor="#f4909e"><?php echo $row['nama_negara'] ?></td> <td bgcolor="#f4909e"><?php echo $row['nama_team'] ?></td> <td bgcolor="#f4909e"><?php echo $row['tgl'] ?></td>

<td bgcolor="#f4909e"><?php echo '<a

href="?menu=detpeserta&id='.$id.'">Det</a>'; ?></td> <td bgcolor="#f4909e"><?php echo '<a

href="?menu=delpeserta&id='.$id.'">Del</a>'; ?></td> </tr>

<?php }} ?> </table> <br>

<a href="?menu=print_all">Laporan</a> Program add Team

<?php

(38)

$q=mysql_query("INSERT INTO `team` (`kode_team`, `nama_team`, `alamat`, `kota`, `tlpn`, `fax`, `email`, `team_manager`, `official1`, `official2`, `official3`) VALUES (NULL, '".$_POST['nama']."', '".$_POST['alamat']."', '".$_POST['kota']."', '".$_POST['telepon']."', '".$_POST['fax']."', '".$_POST['email']."',

'".$_POST['team_manager']."', '".$_POST['official1']."', '".$_POST['official2']."', '".$_POST['official3']."')");

echo "<script>alert(\"registrasi team berhasil!\")</script>"; echo"<script>location.href='?menu=team'</script>"; }

?>

<h2>Tambah Negara</h2> <br><br><br><br>

<form method="POST" > <table border="0">

<tr>

<td>Nama</td> <td>:</td>

<td><input type="text" name="nama" /></td> </tr>

<tr>

<td valign="top">Alamat</td> <td valign="top">:</td>

<td><textarea name="alamat" rows="7" cols="40"></textarea></td> </tr>

<tr>

<td>Kota</td> <td>:</td>

<td><input type="text" name="kota" /></td> </tr>

(39)

<td>Telepon</td> <td>:</td>

<td><input type="text" name="telepon" /></td> </tr>

<tr>

<td>Fax</td> <td>:</td>

<td><input type="text" name="fax" /></td> </tr>

<tr>

<td>Email</td> <td>:</td>

<td><input type="text" name="email" /></td> </tr>

<tr>

<td>Team Manager</td> <td>:</td>

<td><input type="text" name="team_manager" /></td> </tr>

<tr>

<td>Official1</td> <td>:</td>

<td><input type="text" name="official1" /></td> </tr>

<tr>

<td>Official2</td> <td>:</td>

(40)

</tr> <tr>

<td>Official3</td> <td>:</td>

<td><input type="text" name="official3" /></td> </tr>

<tr>

<td>&nbsp;</td> <td>&nbsp;</td>

<td><input type="submit" value="simpan" name="simpan" /></td> </tr>

</table> </form>

Program Del Team <?php

include("../connect/connect.php");

mysql_query("DELETE FROM `team` WHERE kode_team='".$_GET['id']."'"); echo "<script>alert(\"data berhasil dihapus!\")</script>";

echo"<script>location.href='?menu=team'</script>"; ?>

Program Edit Team <?PHP

include("../connect/connect.php");

$query= mysql_query("select * FROM team WHERE kode_team='$_GET[id]'"); $num = mysql_num_rows($query);

for ($i=0;$i<$num;$i++) {

(41)

?>

<h2>Ubah Negara</h2> <br><br><br><br> <form method="POST" > <table border="0">

<tr>

<td>Nama</td> <td>:</td>

<td><input type="text" name="nama" value="<?php echo $f['nama_team']; ?>" /></td>

</tr> <tr>

<td valign="top">Alamat</td> <td valign="top">:</td>

<td><textarea name="alamat" class="required" rows="7" cols="40"><?php echo $f['alamat']; ?></textarea></td>

</tr> <tr>

<td>Kota</td> <td>:</td>

<td><input type="text" name="kota" value="<?php echo $f['kota']; ?>" /></td> </tr>

<tr>

<td>Telepon</td> <td>:</td>

<td><input type="text" name="telepon" value="<?php echo $f['tlpn']; ?>" /></td>

(42)

<td>Fax</td> <td>:</td>

<td><input type="text" name="fax" value="<?php echo $f['fax']; ?>" /></td> </tr>

<tr>

<td>Email</td> <td>:</td>

<td><input type="text" name="email" value="<?php echo $f['email']; ?>" /></td>

</tr> <tr>

<td>Team Manager</td> <td>:</td>

<td><input type="text" name="team_manager" value="<?php echo $f['team_manager']; ?>" /></td>

</tr> <tr>

<td>Official1</td> <td>:</td>

<td><input type="text" name="official1" value="<?php echo $f['official1']; ?>" /></td>

</tr> <tr>

<td>Official2</td> <td>:</td>

<td><input type="text" name="official2" value="<?php echo $f['official2']; ?>" /></td>

(43)

<td>Official3</td> <td>:</td>

<td><input type="text" name="official3" value="<?php echo $f['official3']; ?>" /></td>

</tr> <tr>

<td>&nbsp;</td> <td>&nbsp;</td>

<td><input type="submit" value="simpan" name="simpan" /></td> </tr>

</table> </form> <?php

if (isset($_POST['simpan'])) { include("../connect/connect.php");

$q = mysql_query("UPDATE team SET

nama_team='".$_POST['nama']."',alamat='".$_POST['alamat']."',kota='".$_POST['kot a']."',tlpn='".$_POST['telepon']."',fax='".$_POST['fax']."',email='".$_POST['email']."',tea m_manager='".$_POST['team_manager']."',official1='".$_POST['official1']."',official2=' ".$_POST['official2']."',official3='".$_POST['official3']."' where

kode_team='$_GET[id]'");

echo "<script>alert(\"data berhasil diubah!\")</script>"; echo"<script>location.href='?menu=team'</script>"; }

?>

Program View Team <h2>Team</h2>

<table border="0" width="100%"> <tr bgcolor="#2b2e2e">

(44)

<td align="center"><font color="#FFFFFF"><b>Nama</b></font></td> <td align="center"><font color="#FFFFFF"><b>Alamat</b></font></td> <td align="center"><font color="#FFFFFF"><b>Kota</b></font></td> <td align="center"><font color="#FFFFFF"><b>Telepon</b></font></td> <td align="center"><font color="#FFFFFF"><b>Fax</b></font></td> <td align="center"><font color="#FFFFFF"><b>Email</b></font></td> <td align="center"><font color="#FFFFFF"><b>Team

Manager</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Official1</b></font></td> <td align="center"><font color="#FFFFFF"><b>Official2</b></font></td> <td align="center"><font color="#FFFFFF"><b>Official3</b></font></td> <td>&nbsp;</td>

</tr> <tr> <?PHP

include("../connect/connect.php");

$query= mysql_query("select * FROM team order by kode_team desc"); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); $id = $row['kode_team'];

?>

(45)

<td bgcolor="#f4909e"><?php echo $row['fax'] ?></td> <td bgcolor="#f4909e"><?php echo $row['email'] ?></td>

<td bgcolor="#f4909e"><?php echo $row['team_manager'] ?></td> <td bgcolor="#f4909e"><?php echo $row['official1'] ?></td> <td bgcolor="#f4909e"><?php echo $row['official2'] ?></td> <td bgcolor="#f4909e"><?php echo $row['official3'] ?></td> <td bgcolor="#f4909e"><?php echo '<a

href="?menu=delteam&id='.$id.'">Del</a>'; ?></td> </tr>

<?php }} ?> </table> USER

Program Cart <?php

session_start();

include("connect/connect.php"); $pesan='';

if (isset($_GET['action'])) {

if (isset($_GET['id'])) { $id=(int)$_GET['id']; } else {

$id=0; }

(46)

if (!empty($_SESSION['basket'][$id])) {

$pesan="Jenis Lomba sudah ada di keranjang"; } else {

$_SESSION['basket'][$id]=1; }

break;

case 'update' :

$produk=$_POST['produk'];

foreach ($produk as $key => $val) {

if (!empty($_SESSION['basket'][$key])) { $_SESSION['basket'][$key]=$val; }

} break;

case 'delete' :

if (!empty($_SESSION['basket'][$id])) {

unset($_SESSION['basket'][$id]); } else {

$pesan="Jenis Lomba yang dimaksud tidak ada";

} break;

} }

(47)

<h2>Jenis Lomba yang anda pilih</h2> <br><br><br>

<FORM method="POST" action="?menu=cart&action=update"> <table border="0" width='100%'>

<tr style="background-color:#333333;color:#FFFFFF"> <td>No.</td>

<td>Nama lomba</td> <td>Harga</td> <td>Aksi</td> </tr>

<?php

$no_urut=0; $total=0; $total_harga=0;

foreach ($basket as $key => $val) { $no_urut++;

$query="SELECT * FROM jenis_lomba WHERE kode_jenis='$key' LIMIT 1";

$hasil=mysql_query($query); if ($hasil) {

$data=mysql_fetch_array($hasil); $nama_produk =

$data['nama_produk']; $harga = $data['harga']; $total+=$val;

$total_harga += ($val * $data['biaya']); //total harga

(48)

<tr style='background-color:#ffffff;'> <td><?php echo $no_urut?></td> <td><?php echo $data['nama']?></td>

<td style='background-color:silver;'><?php echo $data['biaya']; ?></td>

<td><A href="?menu=cart&action=delete&id=<?php echo $key?>">Hapus</a></A></td> </tr>

<?php } } ?>

<tr style='background-color:gold;'> <td colspan="2">&nbsp;</td> <td><strong>Total</strong></td>

<td><font color='red' size='3px'><?php echo 'Rp '.$total_harga ?></td> </tr>

</table> </FORM> <?php

echo 'Ada <strong>'.$total.'</strong> jenis lomba<br />'; } else {

echo "Tidak ada jenis lomba yang anda pilih<br />"; }

?> <br>

<a href='?menu=jenis_lomba'>Pilih Lagi Lomba</a> | <a href='?menu=proses_regis'>Selesai</a>

Program Cetak

(49)

<form method="post"> <table border="0"> <tr>

<td>* Masukan Password Anda :</td> <td>&nbsp;</td>

</tr> <tr>

<td>&nbsp;</td>

<td><br><input type="password" name="password"/></td> </tr>

<tr>

<td>&nbsp;</td>

<td><input type="submit" value="Cetak" name="cetak" /></td> </tr>

</table> </form> <?php

include("connect/connect.php"); if(isset($_POST['cetak'])) {

mysql_query("update peserta set status='peserta' where password='".$_POST['password']."'");

echo"<script langunage=\"javascript\"

type=\"text/javascript\">window.open('pages/print.php?password=".$_POST[' password']."','','width=+screen.availWidth-10+,height=+screen.availHeight-55+,scrollbars=yes')</script>";

} ?>

(50)

<h2>Cetak</h2><br /><br /><br /><br /> <form method="post">

<table border="0"> <tr>

<td>* Masukan Password Anda :</td> <td>&nbsp;</td>

</tr> <tr>

<td>&nbsp;</td>

<td><br><input type="password" name="password" /></td> </tr>

<tr>

<td>&nbsp;</td>

<td><input type="submit" value="Cetak" name="cetak" /></td> </tr>

<tr>

<td>&nbsp;</td>

<font color="red"><b>Warning</b> - Dapatkan password anda dengan segera bayar untuk dapat mencetak kartu peserta</font>

</tr> </table> </form> <?php

if(isset($_POST['cetak'])) {

echo"<script langunage=\"javascript\"

type=\"text/javascript\">window.open('pages/print.php?password=".$_POST[' password']."','','width=600,height=300,scrollbars=yes')</script>";

(51)

?>

Program Daftar Jenis

<h2>DAFTAR JENIS LOMBA</h2> <?PHP

include("connect/connect.php");

$query= mysql_query("select * FROM jenis_lomba order by kode_jenis desc"); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); ?>

<p><u><a href="?menu=daftar_juara&id=<?php echo $row['kode_jenis']; ?>"><?php echo $row['nama']; ?></a></u></p>

<?php }} ?>

Program Home <h2>Klasifikasi</h2> <ul >

<?PHP

include("connect/connect.php");

$query= mysql_query("select * FROM klasifikasi order by kode_klasifikasi desc"); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

(52)

<li>

<p>Nama Klasifikasi : <?php echo $row['klasifikasi'] ?></p> <p>Min Umur : <?php echo $row['min_umur'] ?></p> <p>Max Umur : <?php echo $row['max_umur'] ?></p> </li>

<?php }} ?> </ul>

<br /><br /><br /><br /><br /><br /> Program Jenis Lomba

<h2>Jenis Lomba</h2>

<table border="0" width="100%"> <tr bgcolor="#2b2e2e">

<td align="center"><font color="#FFFFFF"><b>Kode Jenis</b></font></td> <td align="center"><font color="#FFFFFF"><b>Tahun Seri</b></font></td> <td align="center"><font color="#FFFFFF"><b>Nama</b></font></td> <td align="center"><font color="#FFFFFF"><b>Tanggal</b></font></td> <td align="center"><font color="#FFFFFF"><b>Kota</b></font></td> <td align="center"><font color="#FFFFFF"><b>Propinsi</b></font></td> <td align="center"><font color="#FFFFFF"><b>Biaya</b></font></td> <td>&nbsp;</td>

</tr> <tr> <?PHP

include("connect/connect.php");

(53)

if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); $id = $row['kode_jenis'];

$number = $row['biaya']; $rp = formatrp($number); ?>

<td bgcolor="#6a94c5"><?php echo $row['kode_jenis'] ?></td> <td bgcolor="#6a94c5"><?php echo $row['tahun_seri'] ?></td> <td bgcolor="#6a94c5"><?php echo $row['nama'] ?></td> <td bgcolor="#6a94c5"><?php echo $row['tgl'] ?></td> <td bgcolor="#6a94c5"><?php echo $row['kota'] ?></td> <td bgcolor="#6a94c5"><?php echo $row['propinsi'] ?></td> <td bgcolor="#6a94c5"><?php echo "Rp. $rp"; ?></td> <td bgcolor="#6a94c5"><?php echo '<a

href="?menu=cart&action=add&id='.$id.'">ikuti</a>'; ?></td> </tr>

<?php }} ?> </table>

Program Peserta

<h2>Daftar PESERTA</h2> <br /><br />

<p align="right">

(54)

<table border="0" width="100%"> <tr bgcolor="#2b2e2e">

<td align="center"><font color="#FFFFFF"><b>ID Peserta</b></font></td> <td align="center"><font color="#FFFFFF"><b>Nama</b></font></td> <td align="center"><font color="#FFFFFF"><b>JK</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Negara</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Team</b></font></td> <td align="center"><font color="#FFFFFF"><b>Klasifikasi</b></font></td> <td align="center"><font color="#FFFFFF"><b>Status</b></font></td> <td>&nbsp;</td>

</tr> <tr> <?PHP

include("connect/connect.php");

$query= mysql_query("select peserta.status, klasifikasi.klasifikasi, peserta.foto, peserta.id_peserta, head_regis.tgl, peserta.nama, peserta.jenis_kelamin,

peserta.no_rekening, peserta.email, negara.nama_negara, team.nama_team FROM peserta, head_regis, negara, team, klasifikasi WHERE

klasifikasi.kode_klasifikasi=head_regis.kode_klasifikasi and peserta.id_peserta=head_regis.id_peserta and

peserta.kode_negara=negara.kode_negara and

peserta.kode_team=team.kode_team order by peserta.id_peserta desc"); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); $id = $row['id_peserta'];

?>

(55)

<td bgcolor="#6a94c5"><?php echo $row['jenis_kelamin'] ?></td>

<td bgcolor="#6a94c5"><?php echo $row['nama_negara'] ?></td> <td bgcolor="#6a94c5"><?php echo $row['nama_team'] ?></td> <td bgcolor="#6a94c5"><?php echo $row['klasifikasi'] ?></td> <td bgcolor="#6a94c5"><?php echo $row['status'] ?></td> <td bgcolor="#6a94c5"><?php echo '<a

href="?menu=detpeserta&id='.$id.'">View</a>'; ?></td> </tr>

<?php }} ?> </table>

Program Peserta Detail <?PHP

include("connect/connect.php");

$query= mysql_query("select klasifikasi.klasifikasi, peserta.alamat, peserta.uci_kode, peserta.status, head_regis.no_regis, detail_regis.kode_jenis, peserta.foto,

peserta.id_peserta, head_regis.tgl, peserta.nama, peserta.jenis_kelamin,

peserta.no_rekening, peserta.email, negara.nama_negara, team.nama_team FROM peserta, head_regis, negara, team, detail_regis, klasifikasi WHERE

peserta.id_peserta=head_regis.id_peserta and peserta.kode_negara=negara.kode_negara and

peserta.kode_team=team.kode_team and head_regis.no_regis=detail_regis.no_regis and klasifikasi.kode_klasifikasi=head_regis.kode_klasifikasi and

peserta.id_peserta='".$_GET['id']."' order by peserta.id_peserta desc"); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); $id = $row['id_peserta'];

(56)

<br>

<h2><b>Mengikuti Lomba</b></h2> <table border="0" width="100%">

<tr bgcolor="grey">

<td>Kode Jenis Lomba</td> <td>Nama Lomba</td> </tr>

<?php

$query= mysql_query("select jenis_lomba.kode_jenis, jenis_lomba.nama,

detail_regis.no_regis, detail_regis.kode_jenis from jenis_lomba,detail_regis where jenis_lomba.kode_jenis=detail_regis.kode_jenis and no_regis='".$noreg."'"); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); ?>

<tr>

<td bgcolor="#f4909e"><?php echo $row['kode_jenis'] ?></td> <td bgcolor="#f4909e"><?php echo $row['nama'] ?></td> </tr>

<?php }} ?> <?php }} ?> </table>

(57)

<h2>Daftar JUARA</h2> <br>

<table border="0" width="100%"> <tr bgcolor="#2b2e2e">

<td align="center"><font color="#FFFFFF"><b>ID Peserta</b></font></td> <td align="center"><font color="#FFFFFF"><b>Nama</b></font></td> <td align="center"><font color="#FFFFFF"><b>JK</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Negara</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Team</b></font></td> <td align="center"><font color="#FFFFFF"><b>waktu</b></font></td> <td align="center"><font color="#FFFFFF"><b>Skor</b></font></td> <td align="center"><font color="#FFFFFF"><b>Juara</b></font></td>

</tr> <tr>

<?PHP

include("connect/connect.php");

$query= mysql_query("select detail_regis.waktu, detail_regis.skor, peserta.foto, peserta.id_peserta, head_regis.tgl, peserta.nama, peserta.jenis_kelamin,

peserta.no_rekening, peserta.email, negara.nama_negara, team.nama_team FROM peserta, head_regis, negara, team, detail_regis WHERE

peserta.id_peserta=head_regis.id_peserta and peserta.kode_negara=negara.kode_negara and

peserta.kode_team=team.kode_team and head_regis.no_regis=detail_regis.no_regis and detail_regis.kode_jenis=$_GET[id] and peserta.status='peserta' order by

detail_regis.skor desc LIMIT 3"); $num = mysql_num_rows($query); if ($num > 0){

for ($i=0; $i < $num; $i++){

(58)

?>

<td bgcolor="#6a94c5" align="center"><?php echo $row['id_peserta'] ?></td>

<td bgcolor="#6a94c5" align="center"><?php echo $row['nama'] ?></td> <td bgcolor="#6a94c5" align="center"><?php echo $row['jenis_kelamin'] ?></td>

<td bgcolor="#6a94c5" align="center"><?php echo $row['nama_negara'] ?></td>

<td bgcolor="#6a94c5" align="center"><?php echo $row['nama_team'] ?></td>

<td bgcolor="#6a94c5" align="center"><?php echo $row['waktu'] ?></td> <td bgcolor="#6a94c5" align="center"><?php echo $row['skor'] ?></td> <td bgcolor="#6a94c5" align="center"><?php echo $i+1 ?></td> </tr>

<?php }} ?> </table>

<a href="?menu=daftar_jenis"><--Back</a> Program Print

<script type="text/javascript"> function printpage()

{

window.print() }

</script> <?PHP

include("../connect/connect.php");

(59)

peserta.jenis_kelamin, peserta.no_rekening, peserta.email, negara.nama_negara, team.nama_team FROM peserta, head_regis, negara, team, klasifikasi WHERE

peserta.id_peserta=head_regis.id_peserta and peserta.kode_negara=negara.kode_negara and peserta.kode_team=team.kode_team and

head_regis.kode_klasifikasi=klasifikasi.kode_klasifikasi and

password='".$_GET['password']."' order by peserta.id_peserta desc"); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); $id = $row['id_peserta'];

$noreg = $row['no_regis']; ?>

<table border="0"> <tr>

<td>Password</td> <td>:</td>

<td><?php echo $row['password']; ?></td> </tr>

<tr>

<td>Nama</td> <td>:</td>

<td><?php echo $row['nama']; ?></td> </tr>

<tr>

<td>Jenis Kelamin</td> <td>:</td>

<td><?php echo $row['jenis_kelamin']; ?></td> </tr>

(60)

<td>Team</td> <td>:</td>

<td><?php echo $row['nama_team']; ?></td> </tr>

<tr>

<td>Umur</td> <td>:</td>

<td><?php echo $row['umur']; ?></td> </tr>

<tr>

<td>Klasifikasi</td> <td>:</td>

<td><?php echo $row['klasifikasi']; ?></td> </tr>

</table>

<table border="0">

<tr bgcolor="#2b2e2e">

<td align="center"><font color="#FFFFFF"><b>Kode Jenis</b></font></td> <td align="center"><font color="#FFFFFF"><b>Tahun Seri</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Nama</b></font></td> <td align="center"><font color="#FFFFFF"><b>Tanggal</b></font></td> <td align="center"><font color="#FFFFFF"><b>Kota</b></font></td>

<td align="center"><font color="#FFFFFF"><b>Provinsi</b></font></td> <td align="center"><font color="#FFFFFF"><b>Biaya</b></font></td> </tr>

<?PHP

(61)

$query= mysql_query("select detail_regis.no_regis, jenis_lomba.kode_jenis, jenis_lomba.tahun_seri, jenis_lomba.nama, jenis_lomba.tgl, jenis_lomba.kota, jenis_lomba.propinsi, jenis_lomba.biaya, detail_regis.no_regis FROM jenis_lomba, detail_regis where jenis_lomba.kode_jenis=detail_regis.kode_jenis and

detail_regis.no_regis='".$noreg."' order by kode_jenis desc"); $num = mysql_num_rows($query);

if ($num > 0){

for ($i=0; $i < $num; $i++){

$row = mysql_fetch_array($query); $id = $row['kode_jenis'];

?> <tr>

<td align="center"><?php echo $row['kode_jenis']; ?></td> <td align="center"><?php echo $row['tahun_seri']; ?></td> <td align="center"><?php echo $row['nama']; ?></td> <td align="center"><?php echo $row['tgl']; ?></td> <td align="center"><?php echo $row['kota']; ?></td> <td align="center"><?php echo $row['propinsi']; ?></td> <td align="center"><?php echo $row['biaya']; ?></td> </tr>

<?php }} ?> </table> <?php }} ?>

Figure

Updating...

References

Scan QR code by 1PDF app
for download now

Install 1PDF app in