Example #1
0
if (is_single()) {
    ?>
				<?php 
    // Show only post author info on Single Pages
    ?>
				<?php 
    independent_publisher_posted_author_card();
    ?>
			<?php 
} else {
    ?>
				<?php 
    // Show Header Image, Site Title, and Site Tagline on everything except Single Pages
    ?>
				<?php 
    independent_publisher_site_info();
    ?>
			<?php 
}
?>
		</div>
		
		<?php 
if (is_home() || is_page() || is_category() || is_tag()) {
    ?>
			<div class="site-published-separator"></div>
		<?php 
}
?>

		<?php 
Example #2
0
 /**
  * Prints HTML with meta information for the current author.
  *
  * @since Independent Publisher 1.0
  */
 function independent_publisher_posted_author()
 {
     /**
      * This function gets called outside the loop (in header.php),
      * so we need to figure out the post author ID and Nice Name manually.
      */
     global $wp_query;
     $post_author_id = $wp_query->post->post_author;
     $post_author_nice_name = get_the_author_meta('display_name', $post_author_id);
     /*printf(
     			'<span class="byline"><span class="author vcard"><a class="url fn n" href="%1$s" title="%2$s" rel="author">%3$s</a></span></span>',
     			esc_url( get_author_posts_url( get_the_author_meta( 'ID', $post_author_id ) ) ),
     			esc_attr( sprintf( __( 'View all posts by %s', 'independent-publisher' ), $post_author_nice_name ) ),
     			esc_html( $post_author_nice_name )
     		);*/
     independent_publisher_site_info(true);
 }