title: How to add pagination in search results
body: <p>My search.php page looks like this:</p>
  
  <pre><code>get_header(); ?&gt;
  &lt;div class="search_result_page"&gt;
  &lt;section class="content-area"&gt;
      &lt;?php
      $paged = ( get_query_var('paged') ) ? get_query_var('paged') : 1;
      if ( have_posts() ) : ?&gt;
          &lt;header class="results_heading"&gt;
              &lt;h6 class="rsults_title"&gt;&lt;?php printf( esc_html__( 'Search Results for: %s', 'satsco' ), '&lt;span class="search_query"&gt;' . get_search_query() . '&lt;/span&gt;' ); ?&gt;&lt;/h6&gt;
          &lt;/header&gt;&lt;!-- .page-header --&gt;
          &lt;div id="result_search"&gt;
          &lt;?php
          /* Start the Loop */
          while ( have_posts() ) : the_post();
  
              get_template_part( 'template-parts/content', 'search' );
  
          endwhile;?&gt;
          &lt;/div&gt;
          &lt;?php
          the_posts_navigation();
      else :
          get_template_part( 'template-parts/content', 'none' );
      endif; ?&gt;
  &lt;/section&gt;&lt;!-- #primary --&gt;
  &lt;/div&gt;
  &lt;?php
  get_footer();
  </code></pre>
  
  <p>Inside the while loop it calls another page called content-search which looks like this?</p>
  
  <pre><code>&lt;article id="post-&lt;?php the_ID(); ?&gt;" &lt;?php post_class(); ?&gt;&gt;
  &lt;header class="entry-header"&gt;
      &lt;?php the_title( sprintf( '&lt;h2 class="entry-title"&gt;&lt;a href="%s" rel="bookmark"&gt;', esc_url( get_permalink() ) ), '&lt;/a&gt;&lt;/h2&gt;' ); ?&gt;
  
      &lt;?php if ( 'post' === get_post_type() ) : ?&gt;
      &lt;?php endif; ?&gt;
  &lt;/header&gt;&lt;!-- .entry-header --&gt;
  &lt;div class="entry-summary"&gt;
      &lt;?php the_excerpt(); ?&gt;
  &lt;/div&gt;&lt;!-- .entry-summary --&gt;
  &lt;/article&gt;&lt;!-- #post-## --&gt;
  </code></pre>
  
  <p>I just noticed now that when I search for "Where", it shows me all the posts that have the word Where.</p>
  
  <p>So, how can I add pagination to it?</p>