Заготовка функции отображения постов из определенной категории
<?php
function all_post_in_cat ($cat_id) {
global $post;
$args = array( 'posts_per_page' => -1, 'offset'=> 1, 'category' => $cat_id );
$myposts = get_posts( $args );
foreach( $myposts as $post ){ setup_postdata($post);
?>
<div class="col-xs-12 col-sm-6 col-md-4 vone">
<a href="#<?php echo s8film_clean( get_the_title($post_id) ); ?>" class="open-popup-link"><?php the_post_thumbnail(); ?></a>
<div id="<?php echo s8film_clean( get_the_title($post_id) ); ?>" class="white-popup mfp-hide">
<div class="video-container">
<?php the_content(); ?>
</div>
</div>
</div>
<?php
}
wp_reset_postdata(); ?>
<div class="clearfix"></div>
<?php
}