• Leo Blanchette

    (@leoclipartillustrationcom)


    File: search.php
    Custom post type query.

    Total results reflects accurate number: 81 results divided up over so many pages.

    However, pagination fails (404) after random pages depending on search. A little digging shows that wordpress “THINKS” there are less pages than what the (accurate) pagination shows.

    This is a deep problem. Been on a week. Can’t finish my project due to this simple yet infinitely complex issue.

    Is there a bug that causes this?

    (it works fine on custom taxonomy templates, just fails on search.php).

Viewing 1 replies (of 1 total)
  • Thread Starter Leo Blanchette

    (@leoclipartillustrationcom)

    Some sort of odd pattern is happening. Note that results_per_page = 5.

    +—————+

    example: search “cute”

    81 results over 17 pages. But only shows results up to 5.

    81/17 = 5.

    After 5 is the 404’s not found.

    +—————+

    example: search “graphic”

    76 results over 16 pages. But only shows results up to 2.

    76/16 = 5

    After 2 is the 404’s not found.

    +—————+

    example: search “professional”

    18 results over 4 pages. But only shows results up to 3.

    18/4 = 5.

    After 3 is the 404’s not found.

    +—————+

    I still need help to figure out why this is happening though. Somewhere wordpress is sabotaging the results, so although pagination is spread out (button-wise) wordpress thinks it ends after some random determined page. But maybe the more qualified minds here might not see it as random. I hope these numbers help.

Viewing 1 replies (of 1 total)
  • The topic ‘Something is Over Riding Pagination, Giving 404s’ is closed to new replies.