⚝
One Hat Cyber Team
⚝
Your IP:
192.168.31.6
Server IP:
192.168.1.11
Server:
Linux pams 6.1.0-29-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.123-1 (2025-01-02) x86_64
PHP Version:
8.2.28
Buat File
|
Buat Folder
Upload File
Eksekusi
Dir :
~
/
var
/
www
/
apik
/
modules
/
Dosen
/
Views
/
Viewing : list.php
<div class="d-flex justify-content-between align-items-sm-center flex-column flex-sm-row mb-3"> <div class="me-4 mb-3 mb-sm-0"> <h1 class="mb-0"><?=$title?></h1> </div> </div> <div class="row"> <div class="col-12 mb-4"> <div class="card border-start-lg border-start-primary h-100 card card-header-actions"> <div class="card-header"> <div id="export"></div> <div class="card-tools"> <a class="btn btn-primary btn-sm" href="<?=base_url('dosen/sync')?>">Sycn</a> </div> </div> <div class="card-body"> <table id="myTable" class="table table-striped table-bordered" style="width:100%"> <thead> <tr> <th>No</th> <th>NIP</th> <th>Nama</th> <th>Aksi</th> </tr> </thead> <tbody> <?php $no =1; foreach ($table as $k) { echo ' <tr> <td>'.$no++.'</td> <td>'.$k->nip.'</td> <td>'.$k->nama.'</td> <td></td> </tr> '; } ?> </tbody> </table> </div> </div> </div> </div> <div class="modal fade" id="add" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel" aria-hidden="true"> <div class="modal-dialog modal-lg" role="document"> <div class="modal-content"> <form method="post" id="form_<?=$title?>"> <div class="modal-header"> <h5 class="modal-title">Form <?=$title?></h5> <button class="btn-close" type="button" data-bs-dismiss="modal" aria-label="Close"></button> </div> <div class="modal-body"> <input type="text" name="data_id" class="d-none" id="data_id"> <?php echo csrf_field(); $c['options'] = ['Ya', 'Tidak']; $c['value'] = [1,2]; $f['options'] = ['Perbulan', 'Pertahun', 'Persemester', 'Perjenjang', '1x']; $f['value'] = [1,2,3,4,5]; echo form_text('nama'); echo form_select('cicilan', $c); echo form_select('frekuensi', $f); ?> </div> <div class="modal-footer"><button class="btn btn-primary" type="submit">Save</button></div> </form> </div> </div> </div> <div class="modal fade" id="reset" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel" aria-hidden="true"> <div class="modal-dialog modal-lg" role="document"> <div class="modal-content"> <form method="post"> <div class="modal-header"> <h5 class="modal-title">Form <?=$title?></h5> <button class="btn-close" type="button" data-bs-dismiss="modal" aria-label="Close"></button> </div> <div class="modal-body"> <input type="text" name="data_id" class="d-none" id="data_id"> <?php echo csrf_field(); echo form_password('password'); echo form_password('konfirmasi password'); ?> </div> <div class="modal-footer"><button class="btn btn-primary" type="submit">Save</button></div> </form> </div> </div> </div> <script type="text/javascript"> $(document).ready(function(){ var table = $('#myTable').DataTable({ dom: 'Bfrtip', buttons: [ // Tombol Excel { extend: 'excelHtml5', exportOptions: { columns: ':not(:last-child)' // Pengecualian kolom terakhir }, className: 'btn btn-primary btn-sm', }, // Tombol PDF { extend: 'pdfHtml5', exportOptions: { columns: ':not(:last-child)' // Pengecualian kolom terakhir }, className: 'btn btn-primary btn-sm', }, // Tombol Print (Sering juga ditambahkan pengecualian untuk kolom yang tidak terlihat) { extend: 'print', exportOptions: { columns: ':visible:not(:last-child)' // Pengecualian kolom terakhir & kolom tersembunyi }, className: 'btn btn-primary btn-sm', } ] }); table.buttons().container().appendTo('#export'); $('.show_pass').on('click', function() { var currentType = $('.password_form').attr('type'); if (currentType === 'text') { $('.password_form').attr('type', 'password'); } else { $('.password_form').attr('type', 'text'); } }); }) function edit(id){ $('#data_id').val(id); if(id != 0){ $.ajax({ url : '<?=base_url()?>/dosen/get/' + id, dataType : 'JSON', success : function(d){ $('#form_<?=$title?>').attr('action', '<?=base_url('dosen/edit')?>'); $('#form_nama').val(d.nama); $('#form_cicilan').val(d.cicilan); $('#form_frekuensi').val(d.frek); } }) }else{ $('#form_<?=$title?>').attr('action', '<?=base_url('dosen/add')?>'); } $('#add').modal('show'); } </script>