';
}
}
echo '
';
$counter = 1;
$img_index = 0;
global $wp_query;
$post_count = $wp_query->post_count;
/* Start the Loop */
while ( have_posts() ) : the_post();
/*
* Include the Post-Type-specific template for the content.
* If you want to override this in a child theme, then include a file
* called content-___.php (where ___ is the Post Type name) and that will be used instead.
*/
if(1 == $counter){
if($first_post_style){
get_template_part( 'template-parts/first-post/first_post_'.esc_attr($first_post_style) );
}else{
/*print the wrapper from the first post if the special first post style is not chosen*/
echo wp_kses_post($wrapper_start);
if(true == $masonry){
blogtory_masonry_post( $image_sizes, $counter, $first_post_style, $img_index);
}else{
get_template_part( 'template-parts/content', get_post_type() );
}
}
}else{
if( 2 == $counter ){
if($first_post_style){
/*print the wrapper from the second post if the special first post style is chosen*/
echo wp_kses_post($wrapper_start);
}
}
if(true == $masonry){
blogtory_masonry_post( $image_sizes, $counter, $first_post_style, $img_index);
}else{
get_template_part( 'template-parts/content', get_post_type() );
}
if($counter == $post_count){
echo wp_kses_post($wrapper_end);
}
}
$counter++;
endwhile;
echo '
';
blogtory_posts_navigation();
else :
get_template_part( 'template-parts/content', 'none' );
endif;
?>