| Server IP : 216.106.184.20 / Your IP : 216.73.216.234 Web Server : LiteSpeed System : Linux asmodeus.in-hell.com 5.14.0-570.58.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Oct 29 06:24:11 EDT 2025 x86_64 User : sekoaid1 ( 1891) PHP Version : 7.3.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /home/sekoaid1/spp.raudhatulfalah.sch.id/tes/admin/combobox/ |
Upload File : |
<?php
include '../../config/koneksi.php';
$idUnit=$_POST['idUnit'];
$idKelas=$_POST['idKelas'];
$tipe_kelas=$_POST['tipe_kelas'];
echo '<option disabled selected value="">- Pilih Kelas -</option>';
if ($tipe_kelas == 'semuaKelas'){
if($idKelas == 'all'){
echo '<option value="all" selected> Semua Kelas </option>';
}else{
echo '<option value="all"> Semua Kelas </option>';
}
}
$query = mysqli_query($koneksi,"SELECT * FROM kelas_siswa WHERE idUnit='$idUnit' AND stdel='0' ORDER BY idKelas ASC");
while ($q = mysqli_fetch_array($query)) {
if ($idKelas == $q['idKelas']){
echo '<option value="'.$q['idKelas'].'" selected>'.$q['nmKelas'].'</option>';
}else{
echo '<option value="'.$q['idKelas'].'">'.$q['nmKelas'].'</option>';
}
}
?>