ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Pagination bug when using with Pages module?

April 25, 2011 3:54pm

Subscribe [4]
  • #1 / Apr 25, 2011 3:54pm

    Jason Turcotte

    102 posts

    Just had a client report a bug to me with their blog and pagination.

    They said they are getting a 404 error when clicking the links for other pages.

    This is, in fact, happening.

    What’s happening is that their blog page “listing” (ie, the main blog page) has a Pages module name so it’s easy to link to. For example: http://example.com/news vs. http://example.com/blog/articles.

    When you are at http://example.com/news and click one of the pagination links, it tries to send you to http://example.com/news/P6, which doesn’t exist, obviously (the correct link would be http://example.com/blog/articles/P6, which DOES work).

    Thoughts? Is this a setting somewhere?

  • #2 / Apr 25, 2011 8:05pm

    giusi

    94 posts

    Hi,

    maybe using the Page module in an index page cause problems with pagination because it looks at the current url to build the links. So you end up with the /news/P url.

  • #3 / Apr 26, 2011 4:04am

    John Henry Donovan

    12339 posts

    Jason,
    To confirm.
    You have a Page created under the Pages Module called news and you also have a template group called news?
    Can you explain a bit more why news is a Page and how it is easer to link to

    Have you tried this without a htaccess in place and reinstating your index.php?

    Generally a Page is just that and not a listing page and not meant to be paginated

    What version and build of EE are you using?

  • #4 / Apr 27, 2011 9:21am

    Jason Turcotte

    102 posts

    Jason,
    To confirm.
    You have a Page created under the Pages Module called news and you also have a template group called news?
    Can you explain a bit more why news is a Page and how it is easer to link to

    Have you tried this without a htaccess in place and reinstating your index.php?

    Generally a Page is just that and not a listing page and not meant to be paginated

    What version and build of EE are you using?

    Hi John,

    After reading your post and having thought about it a bit (including the “why did I do it that way?” question), I think I’ll just remove the Pages module reference to that page. Makes perfect sense.

  • #5 / Apr 27, 2011 9:27am

    Jason Turcotte

    102 posts

    And just to answer the “how does it make it easier to link to…” question:

    The client preferred “example.com/news” vs. “example.com/main/news”.

  • #6 / Apr 28, 2011 10:23am

    Sue Crocker

    26054 posts

    Glad John was able to help. Don’t hesitate to post again as needed.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases