WordPress
2
Вклад в тег
<?php
if ( have_posts() ) :
while ( have_posts() ) : the_post();
if ( $wp_query->current_post == 0 ) :
get_template_part( 'hero' );
endif;
endwhile;
endif;
?>
<?php
if ( have_posts() ) :
while ( have_posts() ) : the_post();
if ( $wp_query->current_post > 0 ) :
get_template_part( 'article' );
endif;
endwhile;
endif;
?>