Using 2 post loops in one template breaks the loop

Posted in: Newspaper
Post count: 161

Hi,

I am trying to use 2 different styled post loops for my category templates. The first post loop only has 1 column with 1 big image and 1 post. This acts as the featured post for the category. A bit like the category grid template. I use a second post loop below with 2 columns and pagination which acts like the normal posts loop. However, because the first posts loop has a 1 limit post number, the second posts loop only shows 1 as well despite having set the posts limit number to 10. So it seems that using more than 1 posts loop on one page breaks the second posts loop. The second post loop uses the same posts limit number as the first one I think. Is this a known issue and how can I fix this? I need to use the posts loop for the first post because the category grid templates won’t let me style it the way I want it to.

Post count: 20688

Hi,

That shouldn’t happen, each loop should use it’s own settings. The post limit set on one of them should not influence the other. Where are you placing the loop elements exactly (page, category etc)?

Let me know and I will test this on my end.
Thanks

Post count: 161

I’m using the loops on my category tagdiv templates.

Post count: 20688

Hi,

Seems to be an issue indeed, it happens when there are multiple loop elements in a category page, author page, tag page, search page. The second loop will use the same post limit value as the second.
I have added this issue on the list and it will be fixed. Thank you for mentioning it and sorry for the inconvenience.

Thanks

Post count: 7

Hi there! Found this thread. Any eta or workaround on how to have multiple page loops on a single page? I ran into this same issue on an Author page I’m creating that would have 3 page loops. Did the offsets to make it work (looks fine in the template) but only shows a single post on the actual author page.

Post count: 20688

Hi,


@HighTechDad
Seems that issue was not solved up to this point, I will make some inquiries about the progress made in this matter. Sorry for this inconvenience.

Post count: 7

Thanks Simion! Appreciate your help!

Viewing 7 posts - 1 through 7 (of 7 total)
The forum ‘Newspaper’ is closed to new topics and replies.