silverstripe-blog/templates/Includes/BlogPagination.ss
Naomi Guyer d33e209ee5 ENHANCEMENT: Template changes
Updated template elements for 3.0.
Made html follow proper heading hierarchy
Optimized generated html so it can be more easily styled.
2012-08-17 15:55:08 +12:00

41 lines
1.1 KiB
Scheme

<% if BlogEntries.MoreThanOnePage %>
<div class="pagination">
<ul class="PageNumbers">
<% if BlogEntries.NotFirstPage %>
<li class="prev">
<a class="paginate-left" href="$BlogEntries.PrevLink" title="View the previous page">&lt;</a>
</li>
<% else %>
<li class="prev disabled">
<a class="paginate-left disabled">&lt;</a>
</li>
<% end_if %>
<% loop BlogEntries.PaginationSummary(4) %>
<% if CurrentBool %>
<li class="active"><a class="disabled">$PageNum</a></li>
<% else %>
<% if Link %>
<li>
<a class="<% if BeforeCurrent %>paginate-left<% else %>paginate-right<% end_if %>" href="$Link">
$PageNum
</a>
</li>
<% else %>
<li class="disabled"><a class="disabled">&hellip;</a></li>
<% end_if %>
<% end_if %>
<% end_loop %>
<% if BlogEntries.NotLastPage %>
<li class="next">
<a class="next paginate-right" href="$BlogEntries.NextLink" title="View the next page">&gt;</a>
</li>
<% else %>
<li class="next disabled">
<a class="next paginate-right disabled">&gt;</a>
</li>
<% end_if %>
</ul>
</div>
<% end_if %>