<?php
include "connect.php";
//definisikan variabel dari Formmhs
//if($_FILES['photo']['size'] > 0 && $_FILES['photo']['error'] == 0){

$id_daf    = $_POST['id_daf'];
$tgl_daf   = $_POST['tgl_daf'];
$no_cmhs   = $_POST['no_cmhs'];
$nm_cmhs   = $_POST['nm_cmhs'];
$kota_lhr  = $_POST['kota_lhr'];
$tgl_lhr   = $_POST['tgl_lhr'];
$agama     = $_POST['agama'];
$jenkel    = $_POST['jenkel'];
$tbadan    = $_POST['tbadan'];
$bbadan    = $_POST['bbadan'];
$alamat    = $_POST['alamat'];
$telp      = $_POST['telp'];
$sklh_asal     = $_POST['sklh_asal'];
$rekomendasi   = $_POST['rekomendasi'];
$wali          = $_POST['wali'];
$prog_study    = $_POST['prog_study'];
$ta    	= $_POST['ta'];
$ket    = $_POST['ket'];

//update data
$updatecmhs ="update cmhs set tgl_daf='$tgl_daf',no_cmhs='$no_cmhs',nm_cmhs='$nm_cmhs',kota_lhr='$kota_lhr',tgl_lhr='$tgl_lhr',agama='$agama',jenkel='$jenkel',tbadan='$tbadan',bbadan='$bbadan',
alamat='$alamat',telp='$telp',sklh_asal='$sklh_asal',rekomendasi='$rekomendasi',wali='$wali',prog_study='$prog_study',ta='$ta',ket='$ket' where id_daf='$id_daf'";
  $hasilcmhs = mysql_query($updatecmhs);
  if ($hasilcmhs)
{
header("location:tampilcmhs.php");
}
else
{
echo "Poses Update Gagal";
}
//}
?>

