46 lines
2.2 KiB
PHP
46 lines
2.2 KiB
PHP
<div class="class-head">
|
|
<h3 class="common-heading"><span><?php echo date('d/m/Y',strtotime($day)); ?></span></h3>
|
|
</div>
|
|
<div class="upcoming-cover">
|
|
<?php if($student_sess){ foreach($student_sess as $c) { ?>
|
|
<div class="upcoming-tab upcoming-classes-tab">
|
|
<div class="class-Sec">
|
|
<h4><?= $c['classroom_name']; ?></h4>
|
|
<p>Grade</p>
|
|
<img src="<?php echo base_url(); ?>assets_teacher/images/class2.png">
|
|
</div>
|
|
<div class="class-det">
|
|
<div class="class-det-head">
|
|
<h5><?= $c['subject_name']; ?></h5>
|
|
<div class="class-time">
|
|
<?php
|
|
$pday = date("l");
|
|
$sessionDay = $c['day'];
|
|
|
|
$s = $c['start'];
|
|
// $s = "15:03";
|
|
$p = date("H:i");
|
|
|
|
$mins = (strtotime($s)-strtotime($p)) / 60;
|
|
|
|
?>
|
|
<?php if(strtolower($pday) === strtolower($sessionDay) && abs($mins) <= 10)
|
|
{ ?>
|
|
<div class="my-class-btn-wrap"><a href = "<?php echo $c['start_link']; ?>" ><button class="join-class-btn">Start</button></a></div>
|
|
|
|
<?php } else { ?>
|
|
|
|
<div class="date"><?php echo ucfirst($c['day']).', '.date('h:i a',strtotime($c['start'])); ?></div>
|
|
<?php } ?>
|
|
<div class="time"><i class="far fa-clock"></i><span><?php echo $c['duration']; ?></span></div>
|
|
</div>
|
|
</div>
|
|
<p>Lorem ipsum dolor in sit amet, of consetetursadip scing elitr, sed. diam </p>
|
|
</div>
|
|
</div>
|
|
<?php }
|
|
} else { ?>
|
|
<div class="upcoming-tab">No Sessions scheduled </div>
|
|
<?php } ?>
|
|
|
|
</div>
|