Skip to content

Instantly share code, notes, and snippets.

@bastianallgeier
Forked from sashtown/author-tagging-link.php
Last active December 21, 2015 10:29
Show Gist options
  • Save bastianallgeier/6292750 to your computer and use it in GitHub Desktop.
Save bastianallgeier/6292750 to your computer and use it in GitHub Desktop.
<?php if(param('author')) {
$author = urldecode(param('author'));
$articles = $pages->find('articles')
->children()
->visible()
->filterBy($author)
->flip()
->paginate(10);
echo '<h1>Author Archives: <em>' . $author . '</em></h1>';
} else {
$articles = $pages->find('articles')
->children()
->visible()
->flip()
->paginate(10);
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment