0
my wordpress search.php page is showing the posts and pages created, how do I show only the posts?
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
<article id="post-<?php the_ID(); ?>" <?php post_class( 'cf' ); ?> role="article">
<header class="entry-header article-header">
CONSTRUÇÃO DO BLOCO
</header>
</article>
<?php endwhile; ?>
<?php else : ?>
It came to work, but with it the pagination of the site to work.
– kaiquemix
True, @kaiquemix. Here in this post suggest doing the same thing as the top colleague, but with more details: https://stackoverflow.com/questions/24838864/how-do-i-get-pagination-to-work-for-get-posts-in-wordpress
– Jullie Utsch