I need to conditionally show include some HTML in a template when a page doesn’t require pagination, ie, on a page where the paginate loop won’t render with the channel:entries loop.
It might be easiest to show with an example. Here is basically what I’m trying to accomplish.
{exp:channel:entries channel="blog_entries" orderby="date" sort="desc" limit='15' paginate='top' disable="member_data|trackbacks"}
{paginate}
{if next_page}<a href="http://{auto_path}" class='next'>Next ></a>{/if}
{if previous_page}<a href="http://{auto_path}" class='prev'>< Previous</a>{/if}
{/paginate}
<!-- An example conditional, SUDO code that does not work, to show
when EE loop does not need to render the paginate loop. -->
{if pagination_needed=='no' }
There is no need to display pagination on this page since all the entries fit on a single page.
{/if}
<!-- End of fake SUDO code block. -->
<article>
<h2><a href="http://{url_title_path=%22blog/entry%22}" title="Read: {title}">{title}</a></h2>
<p> {excerpt}<br />
</article></p>
<p>{/exp:channel:entries}Is there a native way to check to see if the pagination code will render so I can render an alternate loop in it’s spot instead?