• Hi guys. I’m having issues with page 2 of a search result.

    I’ll search for something, the word: “students” for example. I’ll get a results page with “Next Page ?”. When I click on it, it takes me back to my main page, not the second page of the search results.

    I’d disabled my plugins, so I know it’s not them. There’s something wrong perhaps with my theme’s search box? Can anyone offer any advise or have had this same issue too?

    My url is: https://www.cedargrove.k12.nj.us/

    Thanks for any help in advance…..

Viewing 8 replies - 1 through 8 (of 8 total)
  • Thread Starter cedarhs

    (@cedarhs)

    Hi. Any suggestions?

    Thread Starter cedarhs

    (@cedarhs)

    I do notice the code for the next page of search results is this:

    https://www.cedargrove.k12.nj.us/page/2?s=closed

    Instead of other peoples’ sites, where I see the format as:
    https://www.cedargrove.k12.nj.us/page/2/?s=closed

    But even if i change it to “page/2/?s=” it still won’t go to the second page of results.

    More than likely this is an issue with your theme. Try switching to the TwentyTen theme to see if that fixes the issue.

    If I had to guess, I’d say that the theme is missing code similar to the following in the file that renders the search results:

    <?php
    $page = (get_query_var('paged')) ? get_query_var('paged') : 1;
    query_posts( array( 'paged' => $page ) );
    ?>

    Thread Starter cedarhs

    (@cedarhs)

    Hi Curtiss, thanks for your reply. I can’t change the theme, as this is a district site, and doing so would effect all the plugins I have currently in place.

    The code you mentioned above…is that normally found in say…the search.php file?

    If your theme has a search.php file, that’s probably where you’d find it, yes.

    Thread Starter cedarhs

    (@cedarhs)

    Thank you again for your helpful response!

    I’ve been looking at other theme’s search.php, and playing around with posting their code in to my theme’s search.php, with no avail. I’ve also inserted:

    [Code moderated as per the Forum Rules. Please use the pastebin]

    Thread Starter cedarhs

    (@cedarhs)

    just a friendly bump.

    Thread Starter cedarhs

    (@cedarhs)

    bump.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Next Page ? search results not working’ is closed to new replies.