<?php
$day=$this->uri->segment('3');
$month=$this->uri->segment('4');
$year=$this->uri->segment('5');
$check_holiday=$this->CalenderModel->check_day_holiday($day,$month,$year);    
if($check_holiday){
    foreach($check_holiday as $holiday){
        $date=$holiday['holiday_date'];
        $holiday_detail= $holiday['holiday_detail'];
    }    
}
?>

<div class="container-fluid mt-3 mb-3">
    <div class="row">
        <div class="col-sm-12">
            <ul class="breadcrumb">
                <li class="breadcrumb-item">Attendance</li>    
                <li class="breadcrumb-item">Attendance History</li>    
                <li class="breadcrumb-item"><?php echo $day; echo"-"; echo $month; echo"-"; echo $year; ?></li>    
            </ul>
            <div class="bg-success p-3 font-weight-bolder text-white"><?php echo $holiday_detail;?></div>
            <input type="text" id="day" val="<?php echo $day; ?>"><?php echo $day;?>
        </div>
    </div>
</div>

<script>
    $(document).ready(function(){
        var day=$(this).("#day").val();
        alert(day);
    });
</script>