<?PHP
include("index.cma.db.php");
$query = "Select * from $mytable"; 
$result = mysql_query($query); 
if($row = mysql_fetch_array($result)){
?><LINK href="index.css" rel="stylesheet" type="text/css">

<style type="text/css">
<!--
.style1 {color: #FFFFFF}
-->
</style>
<title>CAMELON INSTALLATION</title><table width="100%"  border="0" cellspacing="8" cellpadding="8">
  <tr>
    <td bgcolor="#FF9900"><table width="100%"  border="0" cellspacing="2" cellpadding="2">
      <tr>
        <td><strong>SELAMAT DATANG DI CAMELON INSTALASI </strong></td>
      </tr>
    </table></td>
  </tr>
</table>
<table width="100%"  border="0" cellspacing="8" cellpadding="8">
  <tr>
    <td><strong>MASUKKAN PENDAFTARAN PEGAWAI HINGGA SELESAI </strong></td>
  </tr>
</table>
<table width="100%"  border="0" cellspacing="8" cellpadding="8">
  <tr>
    <td><form name="form3" method="post" action="install.3.php">
      <table width="100%"  border="0" cellspacing="4" cellpadding="4" class="panel">
        <tr>
          <td width="15%">Nama </td>
          <td width="2%">:</td>
          <td width="83%"><input name="p_nama" type="text" id="p_nama" size="40">
            <input name="key" type="hidden" id="key" value="personil">
            <input name="table" type="hidden" id="table" value="tab_personil"></td>
        </tr>
        <tr>
          <td>Pangkat</td>
          <td>:</td>
          <td><select name="p_pangkat" id="p_pangkat">
              <option value="0" selected>---PILIH---</option>
              <option value="1">YUANA DHARMA TU / II.A</option>
              <option value="2">MUDA DHARMA TU/ II.B</option>
              <option value="3">MADYA DHARMA TU / II.C</option>
              <option value="4">SENA DHARMA TU / II.D</option>
              <option value="5">YUANA WIRA TU / III.A</option>
              <option value="6">MUDA WIRA TU / III.B</option>
              <option value="7">MADYA WIRA TU / III.C</option>
              <option value="8">SENA WIRA TU / III.D</option>
              <option value="9">AJUN JAKSA MADYA / IIIA</option>
              <option value="10">AJUN JAKSA / IIIB</option>
              <option value="11">JAKSA PRATAMA / IIIC</option>
              <option value="12">JAKSA MUDA / IIID</option>
              <option value="13">JAKSA MADYA / IVA</option>
              <option value="14">JAKSA UTAMA PRATAMA / IVB</option>
          </select></td>
        </tr>
        <tr>
          <td>Nip</td>
          <td>:</td>
          <td><input name="p_nip" type="text" id="p_nip">
        Masukkan NIP tanpa Spasi </td>
        </tr>
        <tr>
          <td>Nrp</td>
          <td>:</td>
          <td><input name="p_nrp" type="text" id="p_nrp"></td>
        </tr>
        <tr>
          <td>Satuan</td>
          <td>:</td>
          <td><select name="p_jenis" id="p_jenis">
              <option value="1">Jaksa</option>
              <option value="2">TU Pembinaan</option>
              <option value="3">TU Intel</option>
              <option value="4">TU Pidum</option>
              <option value="5">TU Pidsus</option>
              <option value="6">TU Datun</option>
              <option value="7">Honorer</option>
              <option value="0" selected>---Pilih---</option>
          </select></td>
        </tr>
        <tr>
          <td>No Telp </td>
          <td>:</td>
          <td><input name="p_nohp" type="text" id="p_nohp">
        Masukkan tanpa +62 contoh : 081822299999 </td>
        </tr>
        <tr>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
        </tr>
        <tr>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td><input type="submit" name="Submit22" value="Simpan"></td>
        </tr>
        <tr>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
          <td>&nbsp;</td>
        </tr>
      </table>
    </form></td>
  </tr>
</table>
<table width="100%"  border="0" cellspacing="8" cellpadding="8">
  <tr>
    <td width="11%"><a href="index.2.php" class="menu">BACK</a></td>
    <td width="77%"><div align="center"><strong>JIKA SUDAH SELESAI MEMASUKKAN SEMUA INSTANSI KEPOLISIAN SILAHKAN KLIK FINISH </strong></div></td>
    <td width="12%"><a href="../finish.php?do=ask" class="menu">FINISH</a></td>
  </tr>
</table>
<table width="100%"  border="0" cellspacing="8" cellpadding="8">
  <tr>
    <td><?
$link = mysql_connect("$server", "$username", "$password"); mysql_select_db("$database", $link);
$result = mysql_query("SELECT * FROM tab_personil where daftar_status='0'", $link);
$num_rows = mysql_num_rows($result);
echo "Jumlah Personil $num_rows Orang\n<br><br>";
print ('<table width="100%"  border="0" cellspacing="2" cellpadding="2" class="panel">
  <tr>
    <td><table width="100%"  border="0" cellspacing="2" cellpadding="2">
      <tr>
         <td width="80%">Nama Pegawai </td>
		 <td width="20%">Nomor HP </td>
      </tr>');
                   


$SQL     = "SELECT * FROM tab_personil where daftar_status='0' ORDER BY daftar_jenis ASC";
$results = mysql_query($SQL);
while ($row = mysql_fetch_array($results)){
print ('<tr bgcolor="#FFFFCC">
        <td><b>'.$row['daftar_nama'] . '</b></br>');
		if ($row['daftar_pangkat'] == "1") {echo "YUANA DHARMA TU / II.A";} 
		elseif ($row['daftar_pangkat'] == "2") {echo "MUDA DHARMA TU/ II.B";} 
		elseif ($row['daftar_pangkat'] == "3") {echo "MADYA DHARMA TU / II.C";} 
		elseif ($row['daftar_pangkat'] == "4") {echo "SENA DHARMA TU / II.D";} 
		elseif ($row['daftar_pangkat'] == "5") {echo "YUANA WIRA TU / III.A";} 
		elseif ($row['daftar_pangkat'] == "6") {echo "MUDA WIRA TU / III.B";} 
		elseif ($row['daftar_pangkat'] == "7") {echo "MADYA WIRA TU / III.C";} 
		elseif ($row['daftar_pangkat'] == "8") {echo "SENA WIRA TU / III.D";} 
		elseif ($row['daftar_pangkat'] == "9") {echo "AJUN JAKSA MADYA / III.A";} 
  elseif ($row['daftar_pangkat'] == "10") {echo "AJUN JAKSA / III.B";} 
   elseif ($row['daftar_pangkat'] == "11") {echo "JAKSA PRATAMA / III.C";} 
    elseif ($row['daftar_pangkat'] == "12") {echo "JAKSA MUDA / III.D";} 
	else if ($row['daftar_pangkat'] == "13") {echo "JAKSA MADYA / IV.A";} 
	else if ($row['daftar_pangkat'] == "14") {echo "JAKSA UTAMA PRATAMA / IV.B";} 
	elseif ($row['daftar_pangkat'] == "15") {echo "JAKSA UTAMA MADYA / IV.C";} 
	elseif ($row['daftar_pangkat'] == "16") {echo "JAKSA UTAMA / IV.D";} 
else if ($row['daftar_pangkat'] == "0") {echo "Pangkat tidak dapat ditampilan";}
print ('<br>NIP:'.$row['daftar_nip'].'</td><td>'.$row['daftar_nohp'].'</td>');

} 
print ('
    </tr></table></td>
  </tr>
</table>');
?></td>
  </tr>
</table>
<table width="100%"  border="0" cellspacing="8" cellpadding="8">
  <tr>
    <td><div align="center"></div></td>
  </tr>
  <tr>
    <td><div align="center">Camelon By <strong>Chendia Studio Network </strong></div></td>
  </tr>
  <tr>
    <td>&nbsp;</td>
  </tr>
</table>
<? } ?>
