Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- if(!$banner['show']){ ?>
- <div style="margin-top: 10px;"><br/></div>
- <?php }
- ?>
- <section style="margin-top: 58px; margin-bottom: 100px;">
- <?php
- if($banner['show']){
- $this->load->view('form/public/banner',$banner);
- }?>
- <div class="container">
- <div class="row" style=" display: flex;
- flex-wrap: wrap;">
- <?php if($keyword): ?>
- <div class="col-12">
- <h4>Result of "<?=urldecode($keyword)?>"</h4><br/>
- </div>
- <?php else: ?>
- <?php if($show=="all"): ?>
- <div class="col-12">
- <h4>Semua Produk</h4><br/>
- </div>
- <?php endif; ?>
- <?php endif; ?>
- <!-- <div class="col-lg-12">-->
- <!-- <h3>Sedang Pre-order</h3><br/>-->
- <!-- </div>-->
- <?php foreach($form as $row):
- $show=true;
- if($row['start_date']!="0000-00-00"){
- if(strtotime('today') < strtotime($row['start_date'])){
- $show=false;
- }
- }
- if($row['close_date']!="0000-00-00"){
- if(strtotime('today') > strtotime($row['close_date'])){
- $show=false;
- }
- }
- $showAlways=true;
- if($showAlways):
- ?>
- <div class="col-lg-4 shadow" style="display: flex;
- flex-direction: column;" >
- <div class="card" style=" flex: 1;">
- <a href="<?=base_url("detail/".$row['slug'])?>">
- <?php
- $featuredImage = pathinfo($row['featured_image']);
- $ext = $featuredImage['extension'];
- $filenameThumb = $featuredImage['dirname']."/".$featuredImage['filename']."_thumb.".$ext;
- $featuredImage=$row['featured_image'];
- if(file_exists('.'.$filenameThumb)){
- $featuredImage=$filenameThumb;
- }
- ?>
- <img class="card-img-top" src="<?=base_url($featuredImage)?>" alt="<?=$row['group_name']?>">
- </a>
- <div class="card-body">
- <?php if($show): ?>
- <a href="<?=base_url("detail/".$row['slug'])?>" class="btn btn-bluepop" style="margin-top: 10px; border-radius: 30px; padding-left: 30px; padding-right: 30px; padding-top: 7px;padding-bottom: 9px;">Beli Sekarang
- </a><br/>
- <?php if($row['close_date']!="0000-00-00"): ?>
- <small class="text-muted">Dibuka sampai <?=dateFormatMonthName($row['close_date'])?></small>
- <?php endif; ?>
- <?php else: ?>
- <a href="<?=base_url("detail/".$row['slug'])?>" class="btn btn-bluepop" style="margin-top: 10px; border-radius: 30px; padding-left: 30px; padding-right: 30px; padding-top: 7px;padding-bottom: 9px;">Detail</a>
- <br/>
- <small class="text-muted">Pemesanan sudah ditutup</small>
- <?php endif; ?>
- </div>
- <!-- <div class="card-body">-->
- <!-- <a class="text-danger" href="--><?//=base_url("detail/".$row['slug'])?><!--"><h5 class="card-title text-dangerpop">--><?//=$row['group_name']?><!--</h5></a>-->
- <!-- <p class="card-text">--><?//=$row['description_short']?><!--</p>-->
- <!-- </div>-->
- <div class="card-footer d-none">
- </div>
- </div><br/>
- </div>
- <?php
- endif;
- endforeach; ?>
- <div class="col-12"><br/><br/>
- <?=$links?>
- </div>
- </div>
- </div>
- </section>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement