With the site I’m working on, I’m going to display “newer - older” pagination at the bottom of some entires on the homepage.
Here is the code I’m using:
<div id="main-content">
<h2>Gallery</h2>
<ul id="gallery" class="clearfix">
{exp:reeposition}
{exp:weblog:entries weblog="gallery" limit="2" disable="member_data|trackbacks" paginate="bottom"}
<li class="{switch="left|right"}">
<a href="http://{site-url}" title="{title}">{image}</a>
<a href="http://{site-url}">{title}</a>
{entry_date format="%M %d, %Y"}
<?php echo rating_bar({entry_id},'5'); ?>
</li>
{reeposition:item}
{paginate}
<div id="newer-older" class="clearfix">
{if next_page}
<a href="http://{auto_path}"><span class="arrow">«</span> Older</a>
{/if}
{if previous_page}
<a href="http://{auto_path}">Newer <span class="arrow">»</span></a>
{/if}
</div>
{/paginate}
{/reeposition:item}
{/exp:weblog:entries}
</ul>
{reeposition:put_item}
{/exp:reeposition}
</div>
The pagination has to be within the weblog entries tag to work, but with the pagination inside of the weblog entries tag, that means that it’s also inside of the <ul> tag which makes the pagination not display correctly in IE7. The pagination needs to be outside of the <ul> tag to work right.
So, I’m wondering is there a way nest it differently so that the pagination sits outside of the <ul> tag? If not, what’s the problem with the reeposition tags that I’m using? I’m trying to just use that plugin to reposition the pagination outside of the <ul> tag, but that doesn’t see to be working either?
Thanks
Lisa,
Yes, I’m just trying to do next/previous entries.
Here is the homepage where it’s happening: http://www.nicestylesheet.com/blog
I basically just need to figure out a way to move the pagination (next/previous) outside of the </ul>. If you look at the page in IE7 you’ll notice that the next/previous is pushed over to the right. I’m fairly certain this is because it’s nested inside of the <ul> instead of outside the <ul>
Thanks
Ok, well, the code you’re using is for spanning an entry across multiple pages. The proper next/prev entries does not get nested. =)
Lisa,
I’m not sure that’s what I need either. Maybe you can confirm, but it says on the link that you gave me that
“these links can only be used on pages displaying a single entry, such as a “comment” page”
This isn’t a “single entry” page. This page is set up the same way someone would set up a multiple entries page on a weblog. Will this still work?
I still think what I need is the pagination. Weblog Entry and Comment Pagination seems to be what I need (and is what I’m currently using) but it’s nested inside of the weblog entry tag (which I can’t have)
Thoughts?
No problem at all.
Well that’s what I didn’t know I guess.
I don’t think there’s a problem with reeposition per say, but maybe a nesting problem with the weblog entries tag or something else on the page making the reeposition not work?
I don’t know how experienced you are with reeposition, but from my code, does everything looks like it ‘should’ work?
Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.