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 In Article Pages

March 04, 2011 9:18am

Subscribe [4]
  • #1 / Mar 04, 2011 9:18am

    anoopbal

    152 posts

    Hi everyone,

    I have a “popular articles” category in my sidebar and I have paginated it by using a category. It works fine on the home page, but when I go to an article page, I don’t see the category at all. It seems to collapse.

    Here is an example: Article Page
    Home Page

    Thank you.

  • #2 / Mar 04, 2011 3:40pm

    Sue Crocker

    26054 posts

    Hi, anoopbal - Are you trying to get to the category for Advanced by going to:
    http://www.exercisebiology.com/index.php/site/category/advanced/ ??

  • #3 / Mar 04, 2011 3:46pm

    anoopbal

    152 posts

    Hi Sue,

    No. Did you see the “popular article” subheading? It is a category called popular. When you go into an article page, there is nothing under the popular articles subheading. Does it make sense?

    Thanks!

  • #4 / Mar 04, 2011 4:30pm

    Kevin Cupp

    791 posts

    Try turning dynamic off on the main page weblog:entries query, then put url_title={segment_3}. This basically tells EE not to figure out which page should be showing from the URL on its own, you’re instead manually telling it which article to show based on the URL. Also, make sure pagination is disabled on that particular query.

    Basically, EE gets confused when there are multiple dynamic elements on a page that rely on URL segments, and it’s still a problem in EE2. You can see it in action on your homepage where you have two paginated queries, but if you go to the second page on one of them, both of them move to the second page. If what I suggested above doesn’t work, you may be out of luck. It may be worth posting a feature suggestion, a way to work around having multiple dynamic queries in one template.

  • #5 / Mar 05, 2011 9:06am

    anoopbal

    152 posts

    Thanks!

    I had the dynamic=“off” and gave paginate=“bottom”. When I just give dynamic off, the pagination don’t work. When I add the paginate bottom &dynamic; off, they both work.

    But I cannot still get the page to stay. When I go th next page, the other pagination element moves to the next page. I didn’t really understand the url_title thing you wrote about.

  • #6 / Mar 06, 2011 2:43pm

    Greg Salt

    3988 posts

    Hi anoopbal,

    Can you clarify what exactly is not working now? I can see that your Popular Articles pagination seems to be working. I’m afraid I don’t understand this:

    But I cannot still get the page to stay. When I go th next page, the other pagination element moves to the next page.

    Cheers

    Greg

  • #7 / Mar 06, 2011 7:31pm

    anoopbal

    152 posts

    H Greg,

    Thanks. I was replying to Kevin’s post.

    If you got my home page, you can see three different pagination. If I click on one, all the pages in all category moves to the next page though I only want that particular category to paginate.

    I got the initial problem solved when I turned off the dynamic and added the paginate bottom. So now the popular article shows up on article pages too.

  • #8 / Mar 07, 2011 9:28am

    Sue Crocker

    26054 posts

    Sounds like things are working OK again, right? Just making sure.

  • #9 / Mar 07, 2011 9:46am

    anoopbal

    152 posts

    If you got my home page, you can see three different pagination. If I click on one, all the pages in all category moves to the next page though I only want that particular category to paginate.

    Is there anyway I could fix the pagination thing, Sue?

    Thanks a lot.

  • #10 / Mar 07, 2011 3:33pm

    Ingmar

    29245 posts

    I am afraid that won’t work like that. On the front page where you have no single entry selected, it works. Once you do land on a single entry page there is no built-in way to continue pagination without that article. You’d have to either use a bit of custom code, perhaps a custom SQL query, or perhaps use some Ajax to dynamically replace parts of the page?

    Note how this link does not only paginate the articles in your sidebar but, in fact, all entries on your index page, including the “Latest Articles” on the main part of the site.

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

ExpressionEngine News!

#eecms, #events, #releases