title: Wordpress "paginate_links" refers to “Not Found” page
body: <p>I'm trying to make a simple pagination nav menu in WordPress 3.4.2., using the following code:</p>
  
  <pre><code>global $wp_query;
                  $total_pages = $wp_query-&gt;max_num_pages;
  
                  if($total_pages &gt; 1) {
  
                      $current_page = max(1, get_query_var('paged'));
  
                      echo paginate_links(array(
                          'base'  =&gt;  get_pagenum_link(1).'%_%',
                          'format'    =&gt;  'page/%#%',
                          'current'   =&gt;  $current_page,
                          'total'     =&gt;  $total_pages,
                          'prev_next' =&gt;  false,
                          'type'      =&gt;  'list'
  
                      ));
                  }
  </code></pre>
  
  <p>But when I click on a page link it's reffering me to:</p>
  
  <p><strong>Not Found</strong></p>
  
  <p><strong>The requested URL /wptest/page/2 was not found on this server.</strong></p>
  
  <p>I know that it's probably something simple that I missed but I don't know what is it. 
  Is there a way of doing this kind of pagination <em>without external plugins or hacks</em>?</p>
  
  <p>Tried changing the settings in 'Reading' and 'Permalinks' and still no go.. </p>