<?php get_header();
?>

<div class="blog">
    <div class="container">
        <div class="row">
            <div class="col-12 col-md-8">
                <?php while (have_posts()) {
                    the_post();
                ?>
                    <div class="contetn_single single-box">
                        <div class="title_single">
                            <h2><?php the_title(); ?></h2>
                        </div>
                        <div class="dital_single">
                            <i class="fa fa-heart"></i>
                            <span><?php the_views(); ?> </span>
                            <i class="fa fa-comments"></i>
                            <span><?php comments_popup_link('بدون نظر', '1 دیدگاه', '% دیدگاه', '', 'دیدگاه بسته است'); ?></span>
                        </div>
                        <div class="clearfix"></div>
                        <div class="img_single">
                            <img src="<?php the_post_thumbnail_url(); ?>" alt="<?php the_title(); ?> ">
                        </div>
                        <p> <?php the_content(); ?></p>
                    </div>
                    <?php } ?>
<div class="clearfix"></div>

                    <section>
                        <div class="galery-sample-work single-box">
                            <ul>
                                <?php
                                $entair_galery = get_post_meta(get_the_ID(),'group_metabox_sample',true); 
                                foreach($entair_galery as $items){?>
<li><a href="<?php echo $item['pic']; ?>" data-fancybox><img src="<?php echo $items['pic']; ?>" alt=""></a></li>

                                <?php
                                }
                                 ?>
                            </ul>
                        </div>
                    </section>
            </div>
            <?php get_sidebar(); ?>
        </div>
    </div>
</div>
<?php get_footer(); ?>