<?=doctype();?>

<?php 
  header("Expires: Tue, 01 Jan 2000 00:00:00 GMT");
  header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
  header("Cache-Control: no-store, no-cache, must-revalidate, max-age=0");
  header("Cache-Control: post-check=0, pre-check=0", false);
  header("Pragma: no-cache");
  //define('CFG_TIME_ZONE', 'Asia/Makassar');
?>
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" class="no-js">
  <head>
    <title><?=$judul;?> - Medical System Information BBMC Batu Bulan </title>
    <base href="<?=base_url()?>">



    <?php
      echo meta('Content-Type', 'text/html; charset=utf-8', 'equiv');
      echo meta('Resource-Type', 'document', 'equiv');
      echo meta('Cache-control', 'no-cache', 'equiv');
      echo meta('X-UA-Compatible', 'IE=edge', 'equiv');
      echo meta('Content-Style-Type', 'text/css', 'equiv');
      if($this->agent->is_mobile())
          echo meta('viewport','width=device-width, initial-scale=1');

      echo link_tag('media/assets/global/plugins/font-awesome/css/font-awesome.min.css');
      echo link_tag('media/assets/global/plugins/simple-line-icons/simple-line-icons.min.css');
      echo link_tag('media/assets/global/plugins/bootstrap/css/bootstrap.min.css');
      echo link_tag('media/assets/global/plugins/datatables/plugins/bootstrap/dataTables.bootstrap.min.css');
      echo link_tag('media/assets/global/plugins/datatables/plugins/bootstrap/responsive.bootstrap.min.css');
      echo link_tag('media/assets/global/plugins/datatables/plugins/bootstrap/select.bootstrap.min.css');
      echo link_tag('media/assets/global/plugins/material-preloader/css/materialPreloader.min.css');
      echo link_tag('media/assets/global/plugins/material-preloader/css/loader.css');
      echo link_tag('media/assets/global/plugins/sweetalert/sweetalert.css');
      //echo link_tag('media/assets/global/plugins/bootstrap-datepicker/css/bootstrap-datepicker3.min.css');
      echo link_tag('media/assets/global/plugins/select2/select2.min.css');
      echo link_tag('media/assets/global/plugins/uniform/css/uniform.default.min.css');
      echo link_tag('media/assets/global/css/components-md.css');
      echo link_tag('media/assets/global/css/plugins-md.css');
      echo link_tag('media/assets/admin/layout2/css/layout.css');
      echo link_tag('media/assets/admin/layout2/css/themes/grey.css');
      echo link_tag('media/assets/admin/layout2/css/custom.css');
      echo link_tag('media/assets/global/plugins/datatables/extensions/Scroller/css/dataTables.scroller.min.css');
      echo link_tag('media/css/more.css');

      echo script_tag(['media/assets/global/plugins/jquery.min.js',
                       'media/assets/global/plugins/jquery-migrate.min.js']);

      echo script_tag(['media/assets/global/plugins/bootstrap/js/bootstrap.min.js',
                       'media/assets/global/plugins/datatables/media/js/jquery.dataTables.min.js',
                       'media/assets/global/plugins/datatables/plugins/bootstrap/dataTables.bootstrap.min.js',
                       'media/assets/global/plugins/datatables/extensions/Responsive/js/dataTables.responsive.min.js',
                       'media/assets/global/plugins/datatables/plugins/bootstrap/responsive.bootstrap.min.js',
                       'media/assets/global/plugins/datatables/extensions/Scroller/js/dataTables.scroller.min.js',
                       'media/assets/global/plugins/datatables/plugins/bootstrap/dataTables.select.min.js',
                       'media/assets/global/plugins/material-preloader/js/materialPreloader.min.js',
                       'media/assets/global/plugins/sweetalert/sweetalert.min.js',
                       'media/assets/global/plugins/bootstrap-datepicker/js/bootstrap-datepicker.min.js',
                       'media/assets/global/plugins/bootstrap-datepicker/locales/bootstrap-datepicker.id.min.js',                      
                       'media/assets/global/plugins/bootstrap-hover-dropdown/bootstrap-hover-dropdown.min.js',
                       'media/assets/global/plugins/select2/select2.full.min.js',
                       //'media/assets/global/plugins/uniform/jquery.uniform.min.js',
                       'media/assets/global/plugins/select2/i18n/id.js',
                       'media/assets/global/scripts/metronic.js',
                       'media/assets/admin/layout2/scripts/layout.js',
                       'media/js2/dataTables.fixedColumns.min.js'
                      ]);
    ?>
  </head>

        <script src="<?=base_url()?>media/js2/dataTables.buttons.min.js"></script>
        <script src="<?=base_url()?>media/js2/buttons.flash.min.js"></script>
        <script src="<?=base_url()?>media/js2/jszip.min.js"></script>
        <script src="<?=base_url()?>media/js2/pdfmake.min.js"></script>
        <script src="<?=base_url()?>media/js2/vfs_fonts.js"></script>
        <script src="<?=base_url()?>media/js2/buttons.html5.min.js"></script>
        <script src="<?=base_url()?>media/js2/buttons.print.min.js"></script>


       <script type="text/javascript" src="https://cdn.datatables.net/colreorder/1.5.2/js/dataTables.colReorder.min.js"></script>
        <script type="text/javascript" src="https://cdn.datatables.net/buttons/1.6.1/js/buttons.colVis.min.js"></script>





       

  <body class="page-md page-sidebar-closed-hide-logo page-container-bg-solid page-sidebar-closed-hide-logo page-header-fixed">
    <?php 
      if(isset($whole_print)) {
              $this->load->view('front_office/mahasiswa/whole_print'); 
      }  else {
        if($jenis_page == 'select_prefillage') {
          $this->load->view($page); 
        } else if($jenis_page == 'mahasiswa_custom') {
          $this->load->view('mahasiswa/load'); 
        } else {
          $this->load->view($jenis_page.'load'); 
        }           
      } 
    ?>
    <script>
      $(document).ready(function() {    
          Metronic.init();
          Layout.init();
      });
    </script>
  </body>
</html>

<link rel="stylesheet" type="text/css" href="<?php echo base_url()?>media/admin/backend/base/jquery.ui.all.css">
<script type="text/javascript" src="<?php echo base_url('media/admin/date_picker/jquery-ui.js'); ?>"></script>

<audio style="display: none;" controls id="audio"  loop   >
    <source muted="muted" src="<?=base_url()?>media/assets/notif.wav" type="audio/mp3">
    <!--
   <source muted="muted" src="<?=base_url()?>media/assets/notif.mp3" type="audio/mp3">
    -->
</audio>

<button style="display: none;" class="klikplay" onclick="playAudio()" type="button">Play Audio</button>
<button style="display: none;" class="klikpause" onclick="pauseAudio()" type="button">Pause Audio</button> 




<script type="text/javascript">
$( document ).ready(function() {
  //alert(1);
  var audio = document.getElementById("audio");
  var x = document.getElementById("audio"); 
});

function playAudio() { 
  audio.play(); 
} 

function pauseAudio() { 
  audio.pause(); 
} 

setInterval(function () {
    load();
}, 5000);

function load()
{
    $.ajax({
        url: '<?= site_url('front_office/ajax/notif') ?>',
        success: function(data)
        {
            //$('.klikpause').click();
            if(data == 'notif_on'){
                audio.play(); 
                //alert(1);
            }if(data == 'notif_off'){
                audio.pause(); 
            }
                    
        }

    }); 
}

</script>


<!--Start of Tawk.to Script-->
<!--
<script type="text/javascript">
var Tawk_API=Tawk_API||{}, Tawk_LoadStart=new Date();
(function(){
var s1=document.createElement("script"),s0=document.getElementsByTagName("script")[0];
s1.async=true;
s1.src='https://embed.tawk.to/5f8c2475fd4ff5477ea6d3e9/default';
s1.charset='UTF-8';
s1.setAttribute('crossorigin','*');
s0.parentNode.insertBefore(s1,s0);
})();
</script>
-->
<!--End of Tawk.to Script-->
