PENILAIAN SISWA
Hasil Penilaian :
<?php
error_reporting(0);
$tanggal=WKT(date("Y-m-d"));
?>
<link type="text/css" href="<?php echo "$PATH/base/";?>ui.all.css" rel="stylesheet" />
<script type="text/javascript" src="<?php echo "$PATH/";?>jquery-1.3.2.js"></script>
<script type="text/javascript" src="<?php echo "$PATH/";?>ui/ui.core.js"></script>
<script type="text/javascript" src="<?php echo "$PATH/";?>ui/ui.datepicker.js"></script>
<script type="text/javascript" src="<?php echo "$PATH/";?>ui/i18n/ui.datepicker-id.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$("#tanggal").datepicker({
dateFormat : "dd MM yy",
changeMonth : true,
changeYear : true
});
});
</script>
<style>
#table {
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
border-collapse: collapse;
width: 100%;
}
#table td, #table th {
border: 1px solid #ddd;
padding: 8px;
}
#table tr:nth-child(even){background-color: #f2f2f2;}
#table tr:hover {background-color: #ddd;}
#table th {
padding-top: 12px;
padding-bottom: 12px;
text-align: left;
background-color: #808080;
color: white;
}
</style>
<script type="text/javascript">
function PRINT(){
win=window.open('pengujiandetail/print.php','win','width=1000, height=400, menubar=0, scrollbars=1, resizable=0, location=0, toolbar=0, status=0'); }
</script>
<script language="JavaScript">
function buka(url) {window.open(url, 'window_baru', 'width=800,height=600,left=320,top=100,resizable=1,scrollbars=1');}
</script>
<link rel="stylesheet" href="js/jquery-ui.css">
<link rel="stylesheet" href="resources/demos/style.css">
<script src="js/jquery-1.12.4.js"></script>
<script src="js/jquery-ui.js"></script>
<script>
$( function() {
$( "#accordion" ).accordion({
collapsible: true
});
} );
</script>
<?php
$id_penilaian=$_GET["id"];
$sql="select * from `$tbpenilaian` where `id_penilaian`='$id_penilaian'";
$d=getField($conn,$sql);
$id_penilaian=$d["id_penilaian"];
$id_periode=$d["id_periode"];
$bobot1=$d["bobot_1"];
$bobot2=$d["bobot_2"];
$bobot3=$d["bobot_3"];
$bobot4=$d["bobot_4"];
$bobot5=$d["bobot_5"];
$b1=$bobot1;
$b2=$bobot2;
$b3=$bobot3;
$b4=$bobot4;
$b5=$bobot5;
$kelas=$d["kelas"];
$gketerangan=$d["keterangan"];
$sql="select * from `$tbperiode` where `id_periode`='$id_periode'";
$d=getField($conn,$sql);
$nama_periode=$d["nama_periode"];
$status=$d["status"];
$deskripsi=$d["keterangan"];
?>
<div id="accordion">
<h4>Data Penilaian</h4>
<div>
<table id="table">
<tr>
<th width="20%"><label for="id_periode">ID Periode</label>
<th width="9"><div align="center">:
</div>
<th colspan="2"><b><?php echo $id_periode;?></b>
</tr>
<tr>
<td align="left"><label for="periode">Nama Periode</label>
<td><div align="center">:
</div>
<td colspan="2" align="left"><?php echo $nama_periode;?></td>
</tr>
<tr>
<td align="left"><label for="nama">Deskripsi</label>
<td><div align="center">:
</div>
<td colspan="2" align="left"><?php echo $deskripsi;?> #<?php echo $keterangan;?></td>
</tr>
<tr>
<td align="left" valign="top"><label for="periode">Bobot Penilaian (Prosentase)</label>
<td valign="top"><div align="center">:
</div>
<td colspan="2">
<table id="table">
<tr>
<td align="left" >Bobot <?php echo $cr1;?>
<td align="left" >:
<td align="left" ><?php echo $bobot1;?> %</td>
<td align="left" >
<td align="left" >Bobot <?php echo $cr2;?>
<td align="left" >:
<td align="left" ><?php echo $bobot2;?> %</td>
</tr>
<tr>
<td align="left" >Bobot <?php echo $cr3;?>
<td align="left" >:
<td align="left" ><?php echo $bobot3;?> %</td>
<td align="left" >
<td align="left" >Bobot <?php echo $cr4;?>
<td align="left" >:
<td align="left" ><?php echo $bobot4;?> %</td>
</tr>
<tr>
<td align="left" >Bobot <?php echo $cr5;?>
<td align="left" >:
<td align="left" ><?php echo $bobot5;?> %</td>
<td align="left" >
<td align="left" >Catatan
<td align="left" >:
<td align="left" ><?php echo $gketerangan;?></td>
</tr>
</table>
</tr>
</table>
<hr>
Data Penilaian Detail:
<br>
<table id="table">
<tr bgcolor="#036">
<th width="3%"><center>No</th>
<th width="15%"><center>NIS</th>
<th width="30%"><center>Nama Siswa</th>
<th width="10%"><center><?php echo $cr1;?></th>
<th width="10%"><center><?php echo $cr2;?></th>
<th width="10%"><center><?php echo $cr3;?></th>
<th width="10%"><center><?php echo $cr4;?></th>
<th width="10%"><center><?php echo $cr5;?></th>
<th width="10%"><center>Hapus</th>
</tr>
<?php
$no=1;
$sql="select * from `$tbnilai` where id_penilaian='$id_penilaian' order by `id_nilai` asc";
$jum=getJum($conn,$sql);
if($jum > 0){
$g1="";
$g2="";
$g3="";
$g4="";
$g5="";
$arr=getData($conn,$sql);
foreach($arr as $df) {
$id=$df["id_nilai"];
$id_periode=$df["id_periode"];
$nis=$df["nis"];
$nama_siswa=getSiswa($conn,$df["nis"]);
$k1=$df["k_1"];
$k2=$df["k_2"];
$k3=$df["k_3"];
$k4=$df["k_4"];
$k5=$df["k_5"];
$catatan=$df["keterangan"];
$i=$no-1;
$arID[$i]=$id;
$arIP[$i]=$id_periode;
$arI[$i]=$nis;
$arM[$i]=$nama_siswa;
$arK1[$i]=$k1;
$arK2[$i]=$k2;
$arK3[$i]=$k3;
$arK4[$i]=$k4;
$arK5[$i]=$k5;
$arN1[$i]=getN1($k1);
$arN2[$i]=getN1($k2);
$arN3[$i]=getN1($k3);
$arN4[$i]=getN1($k4);
$arN5[$i]=getN1($k5);
$g1.="$arN1[$i];";
$g2.="$arN2[$i];";
$g3.="$arN3[$i];";
$g4.="$arN4[$i];";
$g5.="$arN5[$i];";
$color="#dddddd";
if($no %2==0){$color="#eeeeee";}
echo"<tr bgcolor='$color'>
<td>$no</td>
<td>$nis</td>
<td>$nama_siswa
<td>$k1
<td>$k2
<td>$k3
<td>$k4
<td>$k5
<td align='left'>
<a href='?mnu=saw&id=$id_periode&pro=hapus&kode=$id'><img src='ypathicon/h.png' alt='hapus'
onClick='return confirm(\"Apakah Anda benar-benar akan menghapus $nama_siswa pada data Penilaian_detail ?..\")'></a></td>
</tr>";
$no++;
}//while
}//if
else{echo"<tr><td colspan='7'><blink>Maaf, Data Penilaian_detail belum tersedia...</blink></td></tr>";}
?>
</table>
</div>
<?php
$jump=$i;
$nMax1=max($arN1);
$nMax2=max($arN2);
$nMax3=max($arN3);
$nMax4=max($arN4);
$nMax5=max($arN5);
$nMin1=min($arN1);
$nMin2=min($arN2);
$nMin3=min($arN3);
$nMin4=min($arN4);
$nMin5=min($arN5);
$gmax1="max ($g1)";
$gmax2="max ($g2)";
$gmax3="max ($g3)";
$gmax4="max ($g4)";
$gmax5="max ($g5)";
$gmin1="min ($g1)";
$gmin2="min ($g2)";
$gmin3="min ($g3)";
$gmin4="min ($g4)";
$gmin5="min ($g5)";
for($i=0;$i<=$jump;$i++){
$arM1[$i]=round($arN1[$i]/$nMax1,2);
$arM2[$i]=round($arN2[$i]/$nMax2,2);
$arM3[$i]=round($arN3[$i]/$nMax3,2);
$arM4[$i]=round($arN4[$i]/$nMax4,2);
$arM5[$i]=round($nMax5/$arN5[$i],2);
$arM1S[$i]="$arN1[$i]/$nMax1";
$arM2S[$i]="$arN2[$i]/$nMax2";
$arM3S[$i]="$arN3[$i]/$nMax3";
$arM4S[$i]="$arN4[$i]/$nMax4";
$arM5S[$i]="$arN5[$i]/$nMax5";
$arB1[$i]=$arM1[$i] * $b1/100;
$arB2[$i]=$arM2[$i] * $b2/100;
$arB3[$i]=$arM3[$i] * $b3/100;
$arB4[$i]=$arM4[$i] * $b4/100;
$arB5[$i]=$arM5[$i] * $b5/100;
$asM1[$i]=round($nMin1/$arN1[$i],2);
$asM2[$i]=round($nMin2/$arN2[$i],2);
$asM3[$i]=round($nMin3/$arN3[$i],2);
$asM4[$i]=round($nMin4/$arN4[$i],2);
$asM5[$i]=round($nMin5/$arN5[$i],2);
$asM1S[$i]="$nMin1/$arN1[$i]";
$asM2S[$i]="$nMin2/$arN2[$i]";
$asM3S[$i]="$nMin3/$arN3[$i]";
$asM4S[$i]="$nMin4/$arN4[$i]";
$asM5S[$i]="$nMin5/$arN5[$i]";
$asB1[$i]=$asM1[$i] * $b1/100;
$asB2[$i]=$asM2[$i] * $b2/100;
$asB3[$i]=$asM3[$i] * $b3/100;
$asB4[$i]=$asM4[$i] * $b4/100;
$asB5[$i]=$asM5[$i] * $b5/100;
$SF[$i]="(($nMax1/$arN1[$i]) x $b1/100)+(($nMax2/$arN2[$i]) x $b2/100)+(($nMax3/$arN3[$i]) x $b3/100)+(($nMax4/$arN4[$i]) x $b4/100)+(($arN5[$i]/$nMin5) x $b5/100)";
$VF[$i]=(($nMax1/$arN1[$i]) * $b1/100)+(($nMax2/$arN2[$i]) * $b2/100)+(($nMax3/$arN3[$i]) * $b3/100)+(($nMax4/$arN4[$i]) * $b4/100)+(($arN5[$i]/$nMmin5) * $b5/100);
$VF[$i]=round($VF[$i],2);
$arRekap[$i]=$SF[$i]."=".$VF[$i];
$arKet[$i]="-";
}
//================================================
$gdata="<table id='table'>
<tr bgcolor='#036'>
<th width='3%'><center>#</th>
<th width='30%'><center>Kategori</th>
<th width='10%'><center>$s1</th>
<th width='10%'><center>$s2</th>
<th width='10%'><center>$s3</th>
<th width='10%'><center>$s4</th>
<th width='10%'><center>$s5</th>
</tr>";
$gdata.="
<tr bgcolor='#036'>
<th width='3%'><center>no</th>
<th width='30%'><center>siswa</th>
<th width='10%'><center>$cr1</th>
<th width='10%'><center>$cr2</th>
<th width='10%'><center>$cr3</th>
<th width='10%'><center>$cr4</th>
<th width='10%'><center>$cr5</th>
</tr>";
for($i=0;$i<=$jump;$i++){
$no=$i+1;
$gdata.="<tr>
<td>$no<td>$arM[$i] ($arI[$i])
<td>$arN1[$i]
<td>$arN2[$i]
<td>$arN3[$i]
<td>$arN4[$i]
<td>$arN5[$i]
</tr>";
}
$gdata.="<tr bgcolor='#036'>
<th colspan='2' width='3%' align='left'>Max</th>
<th width='10%'>$gmax1</th>
<th width='10%'>$gmax2</th>
<th width='10%'>$gmax3</th>
<th width='10%'>$gmax4</th>
<th width='10%'>$gmax5</th>
</tr>";
$gdata.="<tr bgcolor='#036'>
<th colspan='2' width='3%' align='left'>Min</th>
<th width='10%'>$gmin1</th>
<th width='10%'>$gmin2</th>
<th width='10%'>$gmin3</th>
<th width='10%'>$gmin4</th>
<th width='10%'>$gmin5</th>
</tr>";
$gdata.="</table>";
$gambar="<img src='ypathfile/saw0.png' width='300' height='200'><br>Pembentukan Matrik Normalisasi";
$gab="<h4>Normalisasi dan Penentuan Batas Min Max</h4><div> $gdata <br>$gambar</div>";
echo $gab;
//================================================
$gdata="<table id='table'>
<tr bgcolor='#036'>
<th width='3%'><center>#</th>
<th width='30%'><center>Kategori</th>
<th width='10%'><center>$s1</th>
<th width='10%'><center>$s2</th>
<th width='10%'><center>$s3</th>
<th width='10%'><center>$s4</th>
<th width='10%'><center>$s5</th>
</tr>";
$gdata.="
<tr bgcolor='#036'>
<th width='3%'><center>no</th>
<th width='30%'><center>siswa</th>
<th width='10%'><center>$cr1</th>
<th width='10%'><center>$cr2</th>
<th width='10%'><center>$cr3</th>
<th width='10%'><center>$cr4</th>
<th width='10%'><center>$cr5</th>
</tr>";
for($i=0;$i<=$jump;$i++){
$no=$i+1;
$gdata.="<tr>
<td>$no<td>$arM[$i] ($arI[$i])
<td>$arM1S[$i]
<td>$arM2S[$i]
<td>$arM3S[$i]
<td>$arM4S[$i]
<td>$arM5S[$i]
</tr>";
}
$gdata.="<tr bgcolor='#036'>
<th colspan='2' width='3%' align='left'>Max</th>
<th width='10%'>$nMax1</th>
<th width='10%'>$nMax2</th>
<th width='10%'>$nMax3</th>
<th width='10%'>$nMax4</th>
<th width='10%'>$nMax5</th>
</tr>";
$gdata.="<tr bgcolor='#036'>
<th colspan='2' width='3%' align='left'>Min</th>
<th width='10%'>$nMin1</th>
<th width='10%'>$nMin2</th>
<th width='10%'>$nMin3</th>
<th width='10%'>$nMin4</th>
<th width='10%'>$nMin5</th>
</tr>";
$gdata.="</table>";
$gambar="<img src='ypathfile/saw0.png' width='300' height='200'><br>Pembentukan Matrik Normalisasi Max - Min";
$gab="<h4>Normalisasi dan Penentuan Batas Min Max</h4><div> $gdata <br>$gambar</div>";
echo $gab;
//============================================
$gdata="<table id='table'>
<tr bgcolor='#036'>
<th width='3%'><center>#</th>
<th width='30%'><center>Kategori</th>
<th width='10%'><center>$s1</th>
<th width='10%'><center>$s2</th>
<th width='10%'><center>$s3</th>
<th width='10%'><center>$s4</th>
<th width='10%'><center>$s5</th>
</tr>";
$gdata.="
<tr bgcolor='#036'>
<th width='3%'><center>no</th>
<th width='30%'><center>siswa</th>
<th width='10%'><center>$cr1</th>
<th width='10%'><center>$cr2</th>
<th width='10%'><center>$cr3</th>
<th width='10%'><center>$cr4</th>
<th width='10%'><center>$cr5</th>
</tr>";
for($i=0;$i<=$jump;$i++){
$no=$i+1;
$gdata.="<tr><td>$no<td>$arM[$i] ($arI[$i])
<td>$arM1[$i]
<td>$arM2[$i]
<td>$arM3[$i]
<td>$arM4[$i]
<td>$asM5[$i]
</tr>";
}
$gdata.="</table>";
$gambar="<img src='ypathfile/saw1.png' width='300' height='200'><br><br>Pembentukan Matrik Normalisasi Max Min";
$gab="<h4>Normalisasi Data Penilaian</h4><div> $gdata
</div>";
echo $gab;
//============================================
$gdata="<table id='table'>
<tr bgcolor='#036'>
<th width='3%'><center>#</th>
<th width='30%'><center>Kategori</th>
<th width='10%'><center>$b1 %</th>
<th width='10%'><center>$b2 %</th>
<th width='10%'><center>$b3 %</th>
<th width='10%'><center>$b4 %</th>
<th width='10%'><center>$b5 %</th>
</tr>";
$gdata.="
<tr bgcolor='#036'>
<th width='3%'><center>No</th>
<th width='30%'><center>Siswa</th>
<th width='10%'><center>$cr1</th>
<th width='10%'><center>$cr2</th>
<th width='10%'><center>$cr3</th>
<th width='10%'><center>$cr4</th>
<th width='10%'><center>$cr5</th>
</tr>";
for($i=0;$i<=$jump;$i++){
$no=$i+1;
$gdata.="<tr><td>$no<td>$arM[$i] ($arI[$i])<td>$arB1[$i]<td>$arB2[$i]<td>$arB3[$i]<td>$arB4[$i]
<td>$arB5[$i]
</tr>";
}
$gdata.="</table>";
$gambar="<img src='ypathfile/saw1.png' width='300' height='200'><br>Pembentukan Matrik Perhitungan SAW + Bobot";
$gab="<h4>Normalisasi dan Pembobotan Data Penilaian</h4><div> $gdata
<hr>
Bobot $cr1 : $b1 %<br>
Bobot $cr2 : $b2 %<br>
Bobot $cr3 : $b3 %<br>
Bobot $cr4 : $b4 %<br>
Bobot $cr5 : $b5 %<br>
$gambar
</div>";
echo $gab;
//==================================
$gdata="<table id='table'>
<tr bgcolor='#036'>
<th width='3%'><center>No</th>
<th width='20%'><center>siswa</th>
<th width='60%'><center>Formula Max-Min</th>
<th width='10%'><center>Bobot</th>
</tr>";
for($i=0;$i<=$jump;$i++){
$no=$i+1;
$gdata.="<tr>
<td>$no
<td>$arM[$i] ($arI[$i])
<td>$SF[$i]
<td>$VF[$i]
</tr>";
}
$gdata.="</table>";
$gab="<h4> Menghitung Nilai <b>Bobot<sub>SAW</sub></b></h4><div> $gdata
</div>";
echo $gab;
$array_count = $jump+1;
for($x = 0; $x < $array_count; $x++){
for($a = 0 ; $a < $array_count - 1 ; $a++){
if($a < $array_count ){
if($VF[$a] < $VF[$a + 1] ){
swap($arID, $a, $a+1);
swap($VF, $a, $a+1);
swap($arM, $a, $a+1);
swap($arI, $a, $a+1);
swap($arRekap, $a, $a+1);
swap($arKet, $a, $a+1);
}
}
}
}
//==================================
$gdata="
Hasil Nilai Akhir dan Rangking.
<br>
Sehingga dapat diambil kesimpulan Data Prestasi Siswa Secara terurut adalah :
<table id='table'>
<tr bgcolor='#036'>
<th width='3%'><center>No</th>
<th width='20%'><center>NIS</th>
<th width='30%'><center>Nama Siswa</th>
<th width='10%'><center>Bobot</th>
<th width='5%'><center>Ranking</th>
<th width='5%'><center>Keterangan</th>
</tr>";
$sql="delete from `$tbhasil` where `id_penilaian`='$id_penilaian'";
$hapus=process($conn,$sql);
for($i=0;$i<=$jump;$i++){
$no=$i+1;
$id_nilai=$arID[$i];
$nis=$arI[$i];
$nama_siswa=getSiswa($conn,$nis);
$rekapitulasi=$arRekap[$i];
$keterangan=$arKet[$i];
$bobot=$VF[$i];
$sql=" INSERT INTO `$tbhasil` (
`id_hasil` ,`kelas` ,
`nis` ,`id_nilai` ,
`id_penilaian` ,
`rekapitulasi` ,
`bobot` ,
`ranking` ,
`keterangan`
) VALUES (
'', '$kelas',
'$nis', '$id_nilai',
'$id_penilaian',
'$rekapitulasi',
'$bobot',
'$no',
'$keterangan'
)";
$simpan=process($conn,$sql);
$gdata.="<tr><td>$no
<td valign='top' align='left'>$nis
<td valign='top' align='left'>
<b><a href='mailto:$email'>$nama_siswa</a></b></td>
<td align='left'>$VF[$i]<td>$no<td>$keterangan</tr>";
}
$gdata.="</table>";
$gab="<h4> Sorting Descending /Bubblesort</h4><div> $gdata
</div>";
echo $gab;
?>
</div>
<?php
if($_GET["pro"]=="hapus"){
$id=$_GET["kode"];
$sql="delete from `$tb_Penilaian` where `id_penilaian`='$id'";
$hapus=process($conn,$sql);
if($hapus) {echo "<script>alert('Data Penilaian_detail $id berhasil dihapus !');document.location.href='?mnu=saw&id=$id_periode';</script>";}
else{echo"<script>alert('Data Penilaian_detail $id gagal dihapus...');document.location.href='?mnu=saw&id=$id_periode';</script>";}
}
function swap(&$arr, $a, $b) {
$tmp = $arr[$a];
$arr[$a] = $arr[$b];
$arr[$b] = $tmp;
}
?>
<?php
$tanggal=WKT(date("Y-m-d"));
$pro="simpan";
$ranking="Aktif";
//$PATH="ypathcss";
?>
<link type="text/css" href="<?php echo "$PATH/base/";?>ui.all.css" rel="stylesheet" />
<script type="text/javascript" src="<?php echo "$PATH/";?>jquery-1.3.2.js"></script>
<script type="text/javascript" src="<?php echo "$PATH/";?>ui/ui.core.js"></script>
<script type="text/javascript" src="<?php echo "$PATH/";?>ui/ui.datepicker.js"></script>
<script type="text/javascript" src="<?php echo "$PATH/";?>ui/i18n/ui.datepicker-id.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$("#tanggal").datepicker({
dateFormat : "dd MM yy",
changeMonth : true,
changeYear : true
});
});
</script>
<script type="text/javascript">
function PRINT(){
win=window.open('hasil/print.php','win','width=1000, height=400, menubar=0, scrollbars=1, resizable=0, location=0, toolbar=0, ranking=0'); }
</script>
<script language="JavaScript">
function buka(url) {window.open(url, 'window_baru', 'width=800,height=600,left=320,top=100,resizable=1,scrollbars=1');}
</script>
<!-- 1 -->
<link rel="stylesheet" href="jsacordeon/jquery-ui.css">
<link rel="stylesheet" href="resources/demos/style.css">
<script src="jsacordeon/jquery-1.12.4.js"></script>
<script src="jsacordeon/jquery-ui.js"></script>
<script>
$( function() {
$( "#accordion" ).accordion({
collapsible: true
});
} );
</script>
<!-- 1 -->
<div id="accordion">
<?php
$sqlq="select distinct(id_penilaian) from `$tbhasil` order by `id_penilaian` desc";
$jumq=getJum($conn,$sqlq);
if($jumq <1){
echo"<h1>Maaf data belum tersedia...</h1>";
}
$arrq=getData($conn,$sqlq);
foreach($arrq as $dq) {
$id_penilaian=$dq["id_penilaian"];
$sql="select * from `$tbpenilaian` where `id_penilaian`='$id_penilaian'";
$d=getField($conn,$sql);
$id_periode=$d["id_periode"];
$bobot_1=$d["bobot_1"];
$bobot_2=$d["bobot_2"];
$bobot_3=$d["bobot_3"];
$bobot_4=$d["bobot_4"];
$bobot_5=$d["bobot_5"];
$kelas=$d["kelas"];
$keterangan=$d["keterangan"];
$sql="select * from `$tbperiode` where `id_periode`='$id_periode'";
$d=getField($conn,$sql);
$nama_periode=$d["nama_periode"];
$status=$d["status"];
?>
<h3>Hasil Penilaian : <?php echo $id_penilaian;?></h3>
<div>
<h1>Periode Terpilih</h1>
<table width="55%" >
<tr>
<td ><label for="id_periode">Id Periode</label>
<td>:<td width="438"><?php echo $id_periode;?>
</td>
<tr>
<td ><label for="nama_periode">Nama periode</label>
<td>:<td width="438"><?php echo $nama_periode;?>
</td>
</tr>
<tr>
<td ><label for="kelas">Kelas</label>
<td>:<td><?php echo $kelas;?></td>
</tr>
<tr>
<td ><label for="bobot_1">Bobot <?php echo $cr1;?> </label>
<td>:<td><?php echo $bobot_1;?> %
</td>
</tr>
<tr>
<td ><label for="bobot_2">Bobot <?php echo $cr2;?> </label>
<td>:<td><?php echo $bobot_2;?> %
</td>
</tr>
<tr>
<td ><label for="bobot_3">Bobot <?php echo $cr3;?> </label>
<td>:<td><?php echo $bobot_3;?> %
</td>
</tr>
<tr>
<td ><label for="bobot_4">Bobot <?php echo $cr4;?></label>
<td>:<td><?php echo $bobot_4;?> %
</td>
</tr>
<tr>
<td ><label for="bobot_5">Bobot <?php echo $cr5;?></label>
<td>:<td><?php echo $bobot_5;?> %
</td>
</tr>
<tr>
<td valign="top"><label for="keterangan">Catatan Penilaian</label>
<td valign="top">:<td><?php echo $keterangan;?>
</td>
</tr>
</table>
| <img src='ypathicon/print.png' alt='PRINT' OnClick="PRINT()"> |
<br>
<hr>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th width="2%">No</td>
<th width="75%">Penilaian Siswa</td>
<th width="5%">Bobot</td>
<th width="5%">Ranking</td>
<th width="9%">Menu</td>
</tr>
</thead>
<tbody>
<?php
$no=1;
$sql="select * from `$tbhasil` where `id_penilaian`='$id_penilaian' order by `ranking` asc";
$jum=getJum($conn,$sql);
if($jum > 0){
$arr=getData($conn,$sql);
foreach($arr as $d) {
$id_hasil=$d["id_hasil"];
$nis=$d["nis"];
$nama=strtoupper(getSiswa($conn,$d["nis"]));
$id_nilai=$d["id_nilai"];
$kelas=$d["kelas"];
$rekapitulasi=$d["rekapitulasi"];
$bobot=$d["bobot"];
$ranking=$d["ranking"];
$keterangan=$d["keterangan"];
echo"<tr>
<td>$no</td>
<td>$nama ($nis)
<br>$rekapitulasi #Cat: $keterangan</td>
<td>$bobot</td>
<td>$ranking</td>
<td><div align='center'>
<a href='?mnu=hasil&pro=hapus&kode=$id_hasil'><img src='ypathicon/ha.png' alt='hapus'
onClick='return confirm(\"Apakah Anda benar-benar akan menghapus $nis pada data hasil ?..\")'></a></div></td>
</tr>";
$no++;
}//while
}//if
else{echo"<tr><td colspan='6'><blink>Maaf, Data hasil belum tersedia...</blink></td></tr>";}
?>
</tbody>
</table>
</div>
<?php }?>
</div>
<?php
if($_GET["pro"]=="hapus"){
$id_hasil=$_GET["kode"];
$sql="delete from `$tbhasil` where `id_hasil`='$id_hasil'";
$hapus=process($conn,$sql);
if($hapus) {echo "<script>alert('Data $id_hasil berhasil dihapus !');document.location.href='?mnu=hasil';</script>";}
else{echo"<script>alert('Data $id_hasil gagal dihapus...');document.location.href='?mnu=hasil';</script>";}
}
?>
NORMALISASI LEVEL 3:
Tidak ada komentar:
Posting Komentar