<?php foreach ($posts as $key => $post): ?>
	<div class="col-md-12 col-sm-12 col-lg-6 ">
		<div class="themestyle_7 singleBlogPost">
			<div class="blogImgVideo">
				<?php if($post['is_video']==0): ?>
					<img src="<?= base_url(html_escape($post['thumb']));?>" alt="">
				<?php else: ?>
					<div class="videoWrapper">
						<iframe src="<?= html_escape($post['thumb']);?>" frameborder="0"></iframe>
					</div>
				<?php endif;?>
			</div>	
			<div class="blogDetails">
				<h3 class="pb-15"><a href="<?= base_url('post/'.$slug.'/'.$post['slug']);?>"><?= character_limiter(html_escape($post['title']),30);?></a></h3>
				<div class="blogBottomDetails border-top">
					<ul>
						<li><i class="fa fa-user-circle"></i> <?=  !empty(users($slug)['name'])?users($slug)['name']:$slug;?></li>
						<li><i class="fa fa-calendar-o"></i> <?= cl_format(html_escape($post['created_at']));?></li>
						<li><i class="fa fa-eye"></i> <?= html_escape($post['hit']);?></li>
					</ul>
					
				</div>
			</div>
		</div>
	</div>
<?php endforeach; ?>