Create New Item
Item Type
File
Folder
Item Name
Search file in folder and subfolders...
Are you sure want to rename?
File Manager
/
idcm_old
/
application
/
views
:
events-20260225101602.php
Advanced Search
Upload
New Item
Settings
Back
Back Up
Advanced Editor
Save
<?php require_once('add_edit_event.php'); $sl =1; $events_data = isset($events_data) ? $events_data : array(); $msg = isset($msg)?$msg:''; $msg_type = isset($msg_type)?$msg_type:''; $this->session->UnsetFlashData(); ?> <style> img { width: 300px; } </style> <div class="content-wrapper"> <!-- Content Header (Page header) --> <section class="content-header"> <h1> News and Events </h1> </section> <section class="content"> <div class="row"> <?php //GPrint($rtype_data);?> <div class="col-xs-12"> <div class="box"> <div class="box-header"> <h3 class="box-title">All Events</h3> <button class="btn btn-primary btn-xs pull-right" type="button" data-ev_id="N" data-edit= "N" data-toggle="modal" data-target="#add_edit_event" > <i class="fa fa-plus"></i> Add Event </button> </div><!-- /.box-header --> <div class="box-body"><div class="table-responsive"> <table id="example" class="table table-bordered table-hover"> <thead> <tr> <th>sl#</th> <th>Title</th> <th>Description</th> <th>Thumbnail</th> <th nowrap>Creation Date</th> <th>Status</th> <th>Action</th> </tr> </thead> <tbody> <?php foreach ($events_data as $ev){ $status = ''; $folder_name = base_url().'img/event/'; $image_link=""; $down_link = $folder_name .$ev->ev_id.'.jpg'; $down_file_name = $ev->ev_id.'.jpg'; $physical_link = BASEPATH."../img/event/$down_file_name"; $isExist='N'; if(file_exists($physical_link)){ $image_link=base_url()."img/event/".$ev->ev_id.".jpg?v=".filemtime(BASEPATH."../img/event/".$ev->ev_id.".jpg"); } else{ $image_link=base_url()."img/Image_not_available.png"; } if($ev->status == 'A'){ $status = "<span class='badge bg-green'>Active</span>"; }else{ $status = "<span class='badge bg-red'>Inactive</span>"; } ?> <tr> <td><?php echo $sl; ?></td> <td><?php echo $ev->ev_title; ?></td> <td class="fixed_td"><?php echo $ev->ev_desc; ?></td> <td> <img width="100" src="<?php echo $image_link;?>" class="" alt="User Image"> </td> <td nowrap><?php echo date('F d, Y', strtotime($ev->ev_date)); ?></td> <td><?php echo $status;?></td> <td nowrap> <button class="btn-xs btn-success" type="button" data-ev_id="<?php echo $ev->ev_id; ?>" data-edit= "Y" data-toggle="modal" data-target="#add_edit_event" > <i class="fa fa-edit"></i> Edit </button> </td> </tr> <?php $sl++;}?> </tbody> </table></div> </div><!-- /.box-body --> </div><!-- /.box --> </div><!-- /.col --> </div><!-- /.row --> </section><!-- /.content --> </div> <script src="<?php echo base_url();?>lib/bootstrap/js/jquery.dataTables.min.js"></script> <script src="<?php echo base_url();?>lib/bootstrap/js/dataTables.bootstrap.min.js"></script> <script> $(document).ready(function() { $('#example').dataTable({ /* Disable initial sort */ "aaSorting": [] }); var toast_msg = '<?php echo $msg;?>'; var msg_type = '<?php echo $msg_type;?>'; if(toast_msg !== null && toast_msg !== '') { var shortCutFunction = msg_type; toastr.options = { positionClass: 'toast-bottom-right' }; var $toast = toastr[shortCutFunction](toast_msg); } } ); </script>