• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer
WordPress a2z

WordPress a2z

WordPress Dynamic API Reference

  • Home
  • Plugins
  • Themes
  • Shortcodes
  • APIs
  • Classes
  • Files
  • Hooks
  • Sitemap
  • Blog
Home / Files / template-parts/post/author-bio.php


Lines:

1 to 41 of 41
<?php

/**
 * The template for displaying author info below posts.
 *
 * @package WordPress
 * @subpackage Twenty_Twenty_One
 * @since Twenty Twenty-One 1.0
 */

?>
<?php if ( (bool) get_the_author_meta( 'description' ) && post_type_supports( get_post_type(), 'author' ) ) : ?>
	<div class="author-bio <?php echo get_option( 'show_avatars' ) ? 'show-avatars' : ''; ?>">
		<?php echo get_avatar( get_the_author_meta( 'ID' ), '85' ); ?>
		<div class="author-bio-content">
			<h2 class="author-title">
			<?php
      printf(
        /* translators: %s: Author name. */
        esc_html__( 'By %s', 'twentytwentyone' ),
        get_the_author()
      );
      ?>
			</h2>
			<p class="author-description"> <?php the_author_meta( 'description' ); ?></p><!-- .author-description -->
			<?php
      printf(
        '<a class="author-link" href="%1$s" rel="author">%2$s</a>',
        esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ),
        sprintf(
          /* translators: %s: Author name. */
          esc_html__( 'View all of %s\'s posts.', 'twentytwentyone' ),
          get_the_author()
        )
      );
      ?>
		</div><!-- .author-bio-content -->
	</div><!-- .author-bio -->
	<?php
endif;
 

 View on GitHub View on Trac

Called by

    Invoked by

      Calls

      Call hooks

      File name: template-parts/post/author-bio.php
      Plugin ref: Twenty Twenty-One
      Version: 1.7
      Deprecated?: No
      API Letters: A,B,P,T

      Published: 9th December 2020 | Last updated: 2nd November 2022

      Primary Sidebar

      Information

      File name: template-parts/post/author-bio.php
      Plugin ref: Twenty Twenty-One
      Version: 1.7
      Deprecated?: No
      API Letters: A,B,P,T

      template-parts/post

      Footer

      WordPress a2z
      WordPress a2z
      WordPress Dynamic API Reference
      WordPress 6.1.1. PHP: 8.0.28
      WordPress a2z
      WordPress core a2z
      Genesis Theme Framework a2z
      Jetpack a2z
      WordPress develop tests
      Easy Digital Downloads a2z
      WooCommerce a2z
      Yoast SEO a2z
      WordPress Blocks

      Site:  wp-a2z.org
      © Copyright WordPress a2z 2014-2023. All rights reserved.


      Website designed and developed by Herb Miller
      Proudly powered by WordPress and oik plugins

      • Home
      • Blog
      • Sitemap
      • Sites