Example #1
0
    $posts_displayed = true;
}
/* --------------------------- DEFAULT: ALL POSTS --------------------------- */
if ($posts_displayed == false) {
    // No other options have been used; no posts have been displayed yet.
    // So display all posts.
    echo '<h1>Archive</h1>';
    perch_blog_custom(array('template' => $template, 'count' => $posts_per_page, 'sort' => $sort_by, 'sort-order' => $sort_order));
}
?>
	    </div>
		<nav class="sidebar">
		    <h2>Filter archive</h2>
		    <!--  By category listing -->
		    <?php 
perch_blog_categories();
?>
		    <!--  By tag -->
		    <?php 
perch_blog_tags();
?>
		    <!--  By year -->
		    <?php 
perch_blog_date_archive_years();
?>
		    <!--  By year and then month - can take parameters for two templates. The first displays the years and the second the months see the default templates for examples -->
		    <?php 
perch_blog_date_archive_months();
?>
    	</nav>
	</div>
			    	<?php 
perch_blog_section(perch_get('s'));
?>

			    	<?php 
perch_blog_custom(['section' => perch_get('s')]);
?>

			    </div>
			</div>
			
			<nav class="sidebar">
			    <h2>Filter archive</h2>
			    <!--  By category listing -->
			    <?php 
perch_blog_categories(array('section' => perch_get('s')));
?>
			    <!--  By tag -->
			    <?php 
perch_blog_tags(array('section' => perch_get('s')));
?>
			    <!--  By year -->
			    <?php 
perch_blog_date_archive_years(array('section' => perch_get('s')));
?>
	    	</nav>
		</div>
		<footer class="layout-footer">
			<div class="wrapper">
				<ul class="social-links">
					<li class="twitter"><a href="#" rel="me">Twitter</a></li>