rendered paste body<?php get_header();
$curauth = (get_query_var('author_name')) ? get_user_by('slug', get_query_var('author_name')) : get_userdata(get_query_var('author'));
?>
<div class="fifteen columns clearfix">
<section id="main-content" class="ten columns alpha">
<?php if ( have_posts() ) { ?>
<?php
/* Queue the first post, that way we know
* what author we're dealing with (if that is the case).
*
* We reset this later so we can run the loop
* properly with a call to rewind_posts().
*/
the_post();
?>
<h1 class="row">
<?php $author = get_the_author(); ?>
Browse Posts by <?php echo $curauth->display_name; ?>
</h1>
<?php
rewind_posts();
// Start The Loop!
while (have_posts()) : the_post(); ?>
<?php get_template_part( 'element', 'excerpt' ); ?>
<?php
// Close the Loop
endwhile;
// No Posts were found, let's show a 404-ish message
} else { ?>
<article id="post-0" class="post error404 not-found">
<header class="entry-header">
<h2 class="entry-title"><?php _e( 'Not Found', 'trusted-authority' ); ?></h2>
</header>
<div class="entry-content">
<p><?php _e( "I'm sorry, we couldn't find what you were looking for... Perhaps searching will help find a related post.", 'trusted-authority' ); ?></p>
<?php get_search_form(); ?>
</div><!-- .entry-content -->
</article><!-- #post-0 -->
<?php } ?>
<?php if( function_exists( 'wp_pagenavi' ) ): ?>
<nav class="post-nav">
<?php wp_pagenavi(); ?>
</nav>
<?php endif;?>
<?php get_template_part( 'element', 'after-posts-widget' ); ?>
</section>
<?php get_sidebar(); ?>
</div>
<?php get_footer(); ?>