PHP - if element present or exist

0 votes
242 views
added Aug 14, 2019 in PHP by LC Marshal Captain (25,790 points)
<?php if (!empty($filter['combine'])):?>
  <h1 class="page-heading">Latest news for:
  <strong id="search-for"><?php echo $filter['combine'];?></strong>
  </h1>
<?php else:?>
  <h1 class="page-heading"><strong id="search-for"><?php echo $category_name;?></strong>
  </h1>
<?php endif;?>  

 

lazacode.org - Malaysia's programming knowledge sharing platform, where everyone can share their finding as reference to others.
...